//===----------------------------------------------------------------------===//
//
// This source file is part of the Soto for AWS open source project
//
// Copyright (c) 2017-2024 the Soto project authors
// Licensed under Apache License v2.0
//
// See LICENSE.txt for license information
// See CONTRIBUTORS.txt for the list of Soto project authors
//
// SPDX-License-Identifier: Apache-2.0
//
//===----------------------------------------------------------------------===//

// THIS FILE IS AUTOMATICALLY GENERATED by https://github.com/soto-project/soto-codegenerator.
// DO NOT EDIT.

#if canImport(FoundationEssentials)
import FoundationEssentials
#else
import Foundation
#endif
@_exported import SotoCore

/// Service object for interacting with AWS DirectoryService service.
///
/// Directory Service Directory Service is a web service that makes it easy for you to setup and run directories in the Amazon Web Services cloud, or connect your Amazon Web Services resources with an existing self-managed Microsoft Active Directory. This guide provides detailed information about Directory Service operations, data types, parameters, and errors. For information about Directory Services features, see Directory Service and the Directory Service Administration Guide.  Amazon Web Services provides SDKs that consist of libraries and sample code for various programming languages and platforms (Java, Ruby, .Net, iOS, Android, etc.). The SDKs provide a convenient way to create programmatic access to Directory Service and other Amazon Web Services services. For more information about the Amazon Web Services SDKs, including how to download and install them, see Tools for Amazon Web Services.
public struct DirectoryService: AWSService {
    // MARK: Member variables

    /// Client used for communication with AWS
    public let client: AWSClient
    /// Service configuration
    public let config: AWSServiceConfig

    // MARK: Initialization

    /// Initialize the DirectoryService client
    /// - parameters:
    ///     - client: AWSClient used to process requests
    ///     - region: Region of server you want to communicate with. This will override the partition parameter.
    ///     - partition: AWS partition where service resides, standard (.aws), china (.awscn), government (.awsusgov).
    ///     - endpoint: Custom endpoint URL to use instead of standard AWS servers
    ///     - middleware: Middleware chain used to edit requests before they are sent and responses before they are decoded 
    ///     - timeout: Timeout value for HTTP requests
    ///     - byteBufferAllocator: Allocator for ByteBuffers
    ///     - options: Service options
    public init(
        client: AWSClient,
        region: SotoCore.Region? = nil,
        partition: AWSPartition = .aws,
        endpoint: String? = nil,
        middleware: AWSMiddlewareProtocol? = nil,
        timeout: TimeAmount? = nil,
        byteBufferAllocator: ByteBufferAllocator = ByteBufferAllocator(),
        options: AWSServiceConfig.Options = []
    ) {
        self.client = client
        self.config = AWSServiceConfig(
            region: region,
            partition: region?.partition ?? partition,
            amzTarget: "DirectoryService_20150416",
            serviceName: "DirectoryService",
            serviceIdentifier: "ds",
            serviceProtocol: .json(version: "1.1"),
            apiVersion: "2015-04-16",
            endpoint: endpoint,
            variantEndpoints: Self.variantEndpoints,
            errorType: DirectoryServiceErrorType.self,
            xmlNamespace: "http://directoryservice.amazonaws.com/doc/2015-04-16/",
            middleware: middleware,
            timeout: timeout,
            byteBufferAllocator: byteBufferAllocator,
            options: options
        )
    }




    /// FIPS and dualstack endpoints
    static var variantEndpoints: [EndpointVariantType: AWSServiceConfig.EndpointVariant] {[
        [.fips]: .init(endpoints: [
            "ca-central-1": "ds-fips.ca-central-1.amazonaws.com",
            "ca-west-1": "ds-fips.ca-west-1.amazonaws.com",
            "us-east-1": "ds-fips.us-east-1.amazonaws.com",
            "us-east-2": "ds-fips.us-east-2.amazonaws.com",
            "us-gov-east-1": "ds-fips.us-gov-east-1.amazonaws.com",
            "us-gov-west-1": "ds-fips.us-gov-west-1.amazonaws.com",
            "us-iso-east-1": "ds-fips.us-iso-east-1.c2s.ic.gov",
            "us-iso-west-1": "ds-fips.us-iso-west-1.c2s.ic.gov",
            "us-isob-east-1": "ds-fips.us-isob-east-1.sc2s.sgov.gov",
            "us-west-1": "ds-fips.us-west-1.amazonaws.com",
            "us-west-2": "ds-fips.us-west-2.amazonaws.com"
        ])
    ]}

    // MARK: API Calls

    /// Accepts a directory sharing request that was sent from the directory owner account.
    @Sendable
    @inlinable
    public func acceptSharedDirectory(_ input: AcceptSharedDirectoryRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> AcceptSharedDirectoryResult {
        try await self.client.execute(
            operation: "AcceptSharedDirectory", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Accepts a directory sharing request that was sent from the directory owner account.
    ///
    /// Parameters:
    ///   - sharedDirectoryId: Identifier of the shared directory in the directory consumer account. This identifier is different for each directory owner account.
    ///   - logger: Logger use during operation
    @inlinable
    public func acceptSharedDirectory(
        sharedDirectoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> AcceptSharedDirectoryResult {
        let input = AcceptSharedDirectoryRequest(
            sharedDirectoryId: sharedDirectoryId
        )
        return try await self.acceptSharedDirectory(input, logger: logger)
    }

    /// If the DNS server for your self-managed domain uses a publicly addressable IP address, you must add a CIDR address block to correctly route traffic to and from your Microsoft AD on Amazon Web Services. AddIpRoutes adds this address block. You can also use AddIpRoutes to facilitate routing traffic that uses public IP ranges from your Microsoft AD on Amazon Web Services to a peer VPC.  Before you call AddIpRoutes, ensure that all of the required permissions have been explicitly granted through a policy. For details about what permissions are required to run the AddIpRoutes operation, see Directory Service API Permissions: Actions, Resources, and Conditions Reference.
    @Sendable
    @inlinable
    public func addIpRoutes(_ input: AddIpRoutesRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> AddIpRoutesResult {
        try await self.client.execute(
            operation: "AddIpRoutes", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// If the DNS server for your self-managed domain uses a publicly addressable IP address, you must add a CIDR address block to correctly route traffic to and from your Microsoft AD on Amazon Web Services. AddIpRoutes adds this address block. You can also use AddIpRoutes to facilitate routing traffic that uses public IP ranges from your Microsoft AD on Amazon Web Services to a peer VPC.  Before you call AddIpRoutes, ensure that all of the required permissions have been explicitly granted through a policy. For details about what permissions are required to run the AddIpRoutes operation, see Directory Service API Permissions: Actions, Resources, and Conditions Reference.
    ///
    /// Parameters:
    ///   - directoryId: Identifier (ID) of the directory to which to add the address block.
    ///   - ipRoutes: IP address blocks, using CIDR format, of the traffic to route. This is often the IP address block of the DNS server used for your self-managed domain.
    ///   - updateSecurityGroupForDirectoryControllers: If set to true, updates the inbound and outbound rules of the security group that has the description: "Amazon Web Services created security group for directory ID directory controllers." Following are the new rules:  Inbound:   Type: Custom UDP Rule, Protocol: UDP, Range: 88, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: Custom UDP Rule, Protocol: UDP, Range: 123, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: Custom UDP Rule, Protocol: UDP, Range: 138, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: Custom UDP Rule, Protocol: UDP, Range: 389, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: Custom UDP Rule, Protocol: UDP, Range: 464, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: Custom UDP Rule, Protocol: UDP, Range: 445, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: Custom TCP Rule, Protocol: TCP, Range: 88, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: Custom TCP Rule, Protocol: TCP, Range: 135, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: Custom TCP Rule, Protocol: TCP, Range: 445, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: Custom TCP Rule, Protocol: TCP, Range: 464, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: Custom TCP Rule, Protocol: TCP, Range: 636, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: Custom TCP Rule, Protocol: TCP, Range: 1024-65535, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: Custom TCP Rule, Protocol: TCP, Range: 3268-33269, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: DNS (UDP), Protocol: UDP, Range: 53, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: DNS (TCP), Protocol: TCP, Range: 53, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: LDAP, Protocol: TCP, Range: 389, Source: Managed Microsoft AD VPC IPv4 CIDR   Type: All ICMP, Protocol: All, Range: N/A, Source: Managed Microsoft AD VPC IPv4 CIDR    Outbound:   Type: All traffic, Protocol: All, Range: All, Destination: 0.0.0.0/0   These security rules impact an internal network interface that is not exposed publicly.
    ///   - logger: Logger use during operation
    @inlinable
    public func addIpRoutes(
        directoryId: String,
        ipRoutes: [IpRoute],
        updateSecurityGroupForDirectoryControllers: Bool? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> AddIpRoutesResult {
        let input = AddIpRoutesRequest(
            directoryId: directoryId, 
            ipRoutes: ipRoutes, 
            updateSecurityGroupForDirectoryControllers: updateSecurityGroupForDirectoryControllers
        )
        return try await self.addIpRoutes(input, logger: logger)
    }

    /// Adds two domain controllers in the specified Region for the specified directory.
    @Sendable
    @inlinable
    public func addRegion(_ input: AddRegionRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> AddRegionResult {
        try await self.client.execute(
            operation: "AddRegion", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Adds two domain controllers in the specified Region for the specified directory.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory to which you want to add Region replication.
    ///   - regionName: The name of the Region where you want to add domain controllers for replication. For example, us-east-1.
    ///   - vpcSettings: 
    ///   - logger: Logger use during operation
    @inlinable
    public func addRegion(
        directoryId: String,
        regionName: String,
        vpcSettings: DirectoryVpcSettings,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> AddRegionResult {
        let input = AddRegionRequest(
            directoryId: directoryId, 
            regionName: regionName, 
            vpcSettings: vpcSettings
        )
        return try await self.addRegion(input, logger: logger)
    }

    /// Adds or overwrites one or more tags for the specified directory. Each directory can have a maximum of 50 tags. Each tag consists of a key and optional value. Tag keys must be unique to each resource.
    @Sendable
    @inlinable
    public func addTagsToResource(_ input: AddTagsToResourceRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> AddTagsToResourceResult {
        try await self.client.execute(
            operation: "AddTagsToResource", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Adds or overwrites one or more tags for the specified directory. Each directory can have a maximum of 50 tags. Each tag consists of a key and optional value. Tag keys must be unique to each resource.
    ///
    /// Parameters:
    ///   - resourceId: Identifier (ID) for the directory to which to add the tag.
    ///   - tags: The tags to be assigned to the directory.
    ///   - logger: Logger use during operation
    @inlinable
    public func addTagsToResource(
        resourceId: String,
        tags: [Tag],
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> AddTagsToResourceResult {
        let input = AddTagsToResourceRequest(
            resourceId: resourceId, 
            tags: tags
        )
        return try await self.addTagsToResource(input, logger: logger)
    }

    /// Cancels an in-progress schema extension to a Microsoft AD directory. Once a schema extension has started replicating to all domain controllers, the task can no longer be canceled. A schema extension can be canceled during any of the following states; Initializing, CreatingSnapshot, and UpdatingSchema.
    @Sendable
    @inlinable
    public func cancelSchemaExtension(_ input: CancelSchemaExtensionRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> CancelSchemaExtensionResult {
        try await self.client.execute(
            operation: "CancelSchemaExtension", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Cancels an in-progress schema extension to a Microsoft AD directory. Once a schema extension has started replicating to all domain controllers, the task can no longer be canceled. A schema extension can be canceled during any of the following states; Initializing, CreatingSnapshot, and UpdatingSchema.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory whose schema extension will be canceled.
    ///   - schemaExtensionId: The identifier of the schema extension that will be canceled.
    ///   - logger: Logger use during operation
    @inlinable
    public func cancelSchemaExtension(
        directoryId: String,
        schemaExtensionId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> CancelSchemaExtensionResult {
        let input = CancelSchemaExtensionRequest(
            directoryId: directoryId, 
            schemaExtensionId: schemaExtensionId
        )
        return try await self.cancelSchemaExtension(input, logger: logger)
    }

    /// Creates an AD Connector to connect to a self-managed directory. Before you call ConnectDirectory, ensure that all of the required permissions have been explicitly granted through a policy. For details about what permissions are required to run the ConnectDirectory operation, see Directory Service API Permissions: Actions, Resources, and Conditions Reference.
    @Sendable
    @inlinable
    public func connectDirectory(_ input: ConnectDirectoryRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ConnectDirectoryResult {
        try await self.client.execute(
            operation: "ConnectDirectory", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Creates an AD Connector to connect to a self-managed directory. Before you call ConnectDirectory, ensure that all of the required permissions have been explicitly granted through a policy. For details about what permissions are required to run the ConnectDirectory operation, see Directory Service API Permissions: Actions, Resources, and Conditions Reference.
    ///
    /// Parameters:
    ///   - connectSettings: A DirectoryConnectSettings object that contains additional information for the operation.
    ///   - description: A description for the directory.
    ///   - name: The fully qualified name of your self-managed directory, such as corp.example.com.
    ///   - password: The password for your self-managed user account.
    ///   - shortName: The NetBIOS name of your self-managed directory, such as CORP.
    ///   - size: The size of the directory.
    ///   - tags: The tags to be assigned to AD Connector.
    ///   - logger: Logger use during operation
    @inlinable
    public func connectDirectory(
        connectSettings: DirectoryConnectSettings,
        description: String? = nil,
        name: String,
        password: String,
        shortName: String? = nil,
        size: DirectorySize,
        tags: [Tag]? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ConnectDirectoryResult {
        let input = ConnectDirectoryRequest(
            connectSettings: connectSettings, 
            description: description, 
            name: name, 
            password: password, 
            shortName: shortName, 
            size: size, 
            tags: tags
        )
        return try await self.connectDirectory(input, logger: logger)
    }

    /// Creates an alias for a directory and assigns the alias to the directory. The alias is used to construct the access URL for the directory, such as http://.awsapps.com.  After an alias has been created, it cannot be deleted or reused, so this operation should only be used when absolutely necessary.
    @Sendable
    @inlinable
    public func createAlias(_ input: CreateAliasRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> CreateAliasResult {
        try await self.client.execute(
            operation: "CreateAlias", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Creates an alias for a directory and assigns the alias to the directory. The alias is used to construct the access URL for the directory, such as http://.awsapps.com.  After an alias has been created, it cannot be deleted or reused, so this operation should only be used when absolutely necessary.
    ///
    /// Parameters:
    ///   - alias: The requested alias. The alias must be unique amongst all aliases in Amazon Web Services. This operation throws an EntityAlreadyExistsException error if the alias already exists.
    ///   - directoryId: The identifier of the directory for which to create the alias.
    ///   - logger: Logger use during operation
    @inlinable
    public func createAlias(
        alias: String,
        directoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> CreateAliasResult {
        let input = CreateAliasRequest(
            alias: alias, 
            directoryId: directoryId
        )
        return try await self.createAlias(input, logger: logger)
    }

    /// Creates an Active Directory computer object in the specified directory.
    @Sendable
    @inlinable
    public func createComputer(_ input: CreateComputerRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> CreateComputerResult {
        try await self.client.execute(
            operation: "CreateComputer", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Creates an Active Directory computer object in the specified directory.
    ///
    /// Parameters:
    ///   - computerAttributes: An array of Attribute objects that contain any LDAP attributes to apply to the computer account.
    ///   - computerName: The name of the computer account.
    ///   - directoryId: The identifier of the directory in which to create the computer account.
    ///   - organizationalUnitDistinguishedName: The fully-qualified distinguished name of the organizational unit to place the computer account in.
    ///   - password: A one-time password that is used to join the computer to the directory. You should generate a random, strong password to use for this parameter.
    ///   - logger: Logger use during operation
    @inlinable
    public func createComputer(
        computerAttributes: [Attribute]? = nil,
        computerName: String,
        directoryId: String,
        organizationalUnitDistinguishedName: String? = nil,
        password: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> CreateComputerResult {
        let input = CreateComputerRequest(
            computerAttributes: computerAttributes, 
            computerName: computerName, 
            directoryId: directoryId, 
            organizationalUnitDistinguishedName: organizationalUnitDistinguishedName, 
            password: password
        )
        return try await self.createComputer(input, logger: logger)
    }

    /// Creates a conditional forwarder associated with your Amazon Web Services directory. Conditional forwarders are required in order to set up a trust relationship with another domain. The conditional forwarder points to the trusted domain.
    @Sendable
    @inlinable
    public func createConditionalForwarder(_ input: CreateConditionalForwarderRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> CreateConditionalForwarderResult {
        try await self.client.execute(
            operation: "CreateConditionalForwarder", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Creates a conditional forwarder associated with your Amazon Web Services directory. Conditional forwarders are required in order to set up a trust relationship with another domain. The conditional forwarder points to the trusted domain.
    ///
    /// Parameters:
    ///   - directoryId: The directory ID of the Amazon Web Services directory for which you are creating the conditional forwarder.
    ///   - dnsIpAddrs: The IP addresses of the remote DNS server associated with RemoteDomainName.
    ///   - remoteDomainName: The fully qualified domain name (FQDN) of the remote domain with which you will set up a trust relationship.
    ///   - logger: Logger use during operation
    @inlinable
    public func createConditionalForwarder(
        directoryId: String,
        dnsIpAddrs: [String],
        remoteDomainName: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> CreateConditionalForwarderResult {
        let input = CreateConditionalForwarderRequest(
            directoryId: directoryId, 
            dnsIpAddrs: dnsIpAddrs, 
            remoteDomainName: remoteDomainName
        )
        return try await self.createConditionalForwarder(input, logger: logger)
    }

    /// Creates a Simple AD directory. For more information, see Simple Active Directory in the Directory Service Admin Guide. Before you call CreateDirectory, ensure that all of the required permissions have been explicitly granted through a policy. For details about what permissions are required to run the CreateDirectory operation, see Directory Service API Permissions: Actions, Resources, and Conditions Reference.
    @Sendable
    @inlinable
    public func createDirectory(_ input: CreateDirectoryRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> CreateDirectoryResult {
        try await self.client.execute(
            operation: "CreateDirectory", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Creates a Simple AD directory. For more information, see Simple Active Directory in the Directory Service Admin Guide. Before you call CreateDirectory, ensure that all of the required permissions have been explicitly granted through a policy. For details about what permissions are required to run the CreateDirectory operation, see Directory Service API Permissions: Actions, Resources, and Conditions Reference.
    ///
    /// Parameters:
    ///   - description: A description for the directory.
    ///   - name: The fully qualified name for the directory, such as corp.example.com.
    ///   - password: The password for the directory administrator. The directory creation process creates a directory administrator account with the user name Administrator and this password. If you need to change the password for the administrator account, you can use the ResetUserPassword API call. The regex pattern for this string is made up of the following conditions:   Length (?=^.{8,64}$) – Must be between 8 and 64 characters   AND any 3 of the following password complexity rules required by Active Directory:   Numbers and upper case and lowercase (?=.*\d)(?=.*[A-Z])(?=.*[a-z])   Numbers and special characters and lower case (?=.*\d)(?=.*[^A-Za-z0-9\s])(?=.*[a-z])   Special characters and upper case and lower case (?=.*[^A-Za-z0-9\s])(?=.*[A-Z])(?=.*[a-z])   Numbers and upper case and special characters (?=.*\d)(?=.*[A-Z])(?=.*[^A-Za-z0-9\s])   For additional information about how Active Directory passwords are enforced, see Password must meet complexity requirements on the Microsoft website.
    ///   - shortName: The NetBIOS name of the directory, such as CORP.
    ///   - size: The size of the directory.
    ///   - tags: The tags to be assigned to the Simple AD directory.
    ///   - vpcSettings: A DirectoryVpcSettings object that contains additional information for the operation.
    ///   - logger: Logger use during operation
    @inlinable
    public func createDirectory(
        description: String? = nil,
        name: String,
        password: String,
        shortName: String? = nil,
        size: DirectorySize,
        tags: [Tag]? = nil,
        vpcSettings: DirectoryVpcSettings? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> CreateDirectoryResult {
        let input = CreateDirectoryRequest(
            description: description, 
            name: name, 
            password: password, 
            shortName: shortName, 
            size: size, 
            tags: tags, 
            vpcSettings: vpcSettings
        )
        return try await self.createDirectory(input, logger: logger)
    }

    /// Creates a subscription to forward real-time Directory Service domain controller security logs to the specified Amazon CloudWatch log group in your Amazon Web Services account.
    @Sendable
    @inlinable
    public func createLogSubscription(_ input: CreateLogSubscriptionRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> CreateLogSubscriptionResult {
        try await self.client.execute(
            operation: "CreateLogSubscription", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Creates a subscription to forward real-time Directory Service domain controller security logs to the specified Amazon CloudWatch log group in your Amazon Web Services account.
    ///
    /// Parameters:
    ///   - directoryId: Identifier of the directory to which you want to subscribe and receive real-time logs to your specified CloudWatch log group.
    ///   - logGroupName: The name of the CloudWatch log group where the real-time domain controller logs are forwarded.
    ///   - logger: Logger use during operation
    @inlinable
    public func createLogSubscription(
        directoryId: String,
        logGroupName: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> CreateLogSubscriptionResult {
        let input = CreateLogSubscriptionRequest(
            directoryId: directoryId, 
            logGroupName: logGroupName
        )
        return try await self.createLogSubscription(input, logger: logger)
    }

    /// Creates a Microsoft AD directory in the Amazon Web Services Cloud. For more information, see Managed Microsoft AD in the Directory Service Admin Guide. Before you call CreateMicrosoftAD, ensure that all of the required permissions have been explicitly granted through a policy. For details about what permissions are required to run the CreateMicrosoftAD operation, see Directory Service API Permissions: Actions, Resources, and Conditions Reference.
    @Sendable
    @inlinable
    public func createMicrosoftAD(_ input: CreateMicrosoftADRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> CreateMicrosoftADResult {
        try await self.client.execute(
            operation: "CreateMicrosoftAD", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Creates a Microsoft AD directory in the Amazon Web Services Cloud. For more information, see Managed Microsoft AD in the Directory Service Admin Guide. Before you call CreateMicrosoftAD, ensure that all of the required permissions have been explicitly granted through a policy. For details about what permissions are required to run the CreateMicrosoftAD operation, see Directory Service API Permissions: Actions, Resources, and Conditions Reference.
    ///
    /// Parameters:
    ///   - description: A description for the directory. This label will appear on the Amazon Web Services console Directory Details page after the directory is created.
    ///   - edition: Managed Microsoft AD is available in two editions: Standard and Enterprise. Enterprise is the default.
    ///   - name: The fully qualified domain name for the Managed Microsoft AD directory, such as corp.example.com. This name will resolve inside your VPC only. It does not need to be publicly resolvable.
    ///   - password: The password for the default administrative user named Admin. If you need to change the password for the administrator account, you can use the ResetUserPassword API call.
    ///   - shortName: The NetBIOS name for your domain, such as CORP. If you don't specify a NetBIOS name, it will default to the first part of your directory DNS. For example, CORP for the directory DNS corp.example.com.
    ///   - tags: The tags to be assigned to the Managed Microsoft AD directory.
    ///   - vpcSettings: Contains VPC information for the CreateDirectory or CreateMicrosoftAD operation.
    ///   - logger: Logger use during operation
    @inlinable
    public func createMicrosoftAD(
        description: String? = nil,
        edition: DirectoryEdition? = nil,
        name: String,
        password: String,
        shortName: String? = nil,
        tags: [Tag]? = nil,
        vpcSettings: DirectoryVpcSettings,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> CreateMicrosoftADResult {
        let input = CreateMicrosoftADRequest(
            description: description, 
            edition: edition, 
            name: name, 
            password: password, 
            shortName: shortName, 
            tags: tags, 
            vpcSettings: vpcSettings
        )
        return try await self.createMicrosoftAD(input, logger: logger)
    }

    /// Creates a snapshot of a Simple AD or Microsoft AD directory in the Amazon Web Services cloud.  You cannot take snapshots of AD Connector directories.
    @Sendable
    @inlinable
    public func createSnapshot(_ input: CreateSnapshotRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> CreateSnapshotResult {
        try await self.client.execute(
            operation: "CreateSnapshot", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Creates a snapshot of a Simple AD or Microsoft AD directory in the Amazon Web Services cloud.  You cannot take snapshots of AD Connector directories.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory of which to take a snapshot.
    ///   - name: The descriptive name to apply to the snapshot.
    ///   - logger: Logger use during operation
    @inlinable
    public func createSnapshot(
        directoryId: String,
        name: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> CreateSnapshotResult {
        let input = CreateSnapshotRequest(
            directoryId: directoryId, 
            name: name
        )
        return try await self.createSnapshot(input, logger: logger)
    }

    /// Directory Service for Microsoft Active Directory allows you to configure trust relationships. For example, you can establish a trust between your Managed Microsoft AD directory, and your existing self-managed Microsoft Active Directory. This would allow you to provide users and groups access to resources in either domain, with a single set of credentials. This action initiates the creation of the Amazon Web Services side of a trust relationship between an Managed Microsoft AD directory and an external domain. You can create either a forest trust or an external trust.
    @Sendable
    @inlinable
    public func createTrust(_ input: CreateTrustRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> CreateTrustResult {
        try await self.client.execute(
            operation: "CreateTrust", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Directory Service for Microsoft Active Directory allows you to configure trust relationships. For example, you can establish a trust between your Managed Microsoft AD directory, and your existing self-managed Microsoft Active Directory. This would allow you to provide users and groups access to resources in either domain, with a single set of credentials. This action initiates the creation of the Amazon Web Services side of a trust relationship between an Managed Microsoft AD directory and an external domain. You can create either a forest trust or an external trust.
    ///
    /// Parameters:
    ///   - conditionalForwarderIpAddrs: The IP addresses of the remote DNS server associated with RemoteDomainName.
    ///   - directoryId: The Directory ID of the Managed Microsoft AD directory for which to establish the trust relationship.
    ///   - remoteDomainName: The Fully Qualified Domain Name (FQDN) of the external domain for which to create the trust relationship.
    ///   - selectiveAuth: Optional parameter to enable selective authentication for the trust.
    ///   - trustDirection: The direction of the trust relationship.
    ///   - trustPassword: The trust password. The trust password must be the same password that was used when creating the trust relationship on the external domain.
    ///   - trustType: The trust relationship type. Forest is the default.
    ///   - logger: Logger use during operation
    @inlinable
    public func createTrust(
        conditionalForwarderIpAddrs: [String]? = nil,
        directoryId: String,
        remoteDomainName: String,
        selectiveAuth: SelectiveAuth? = nil,
        trustDirection: TrustDirection,
        trustPassword: String,
        trustType: TrustType? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> CreateTrustResult {
        let input = CreateTrustRequest(
            conditionalForwarderIpAddrs: conditionalForwarderIpAddrs, 
            directoryId: directoryId, 
            remoteDomainName: remoteDomainName, 
            selectiveAuth: selectiveAuth, 
            trustDirection: trustDirection, 
            trustPassword: trustPassword, 
            trustType: trustType
        )
        return try await self.createTrust(input, logger: logger)
    }

    /// Deletes a conditional forwarder that has been set up for your Amazon Web Services directory.
    @Sendable
    @inlinable
    public func deleteConditionalForwarder(_ input: DeleteConditionalForwarderRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DeleteConditionalForwarderResult {
        try await self.client.execute(
            operation: "DeleteConditionalForwarder", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Deletes a conditional forwarder that has been set up for your Amazon Web Services directory.
    ///
    /// Parameters:
    ///   - directoryId: The directory ID for which you are deleting the conditional forwarder.
    ///   - remoteDomainName: The fully qualified domain name (FQDN) of the remote domain with which you are deleting the conditional forwarder.
    ///   - logger: Logger use during operation
    @inlinable
    public func deleteConditionalForwarder(
        directoryId: String,
        remoteDomainName: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DeleteConditionalForwarderResult {
        let input = DeleteConditionalForwarderRequest(
            directoryId: directoryId, 
            remoteDomainName: remoteDomainName
        )
        return try await self.deleteConditionalForwarder(input, logger: logger)
    }

    /// Deletes an Directory Service directory. Before you call DeleteDirectory, ensure that all of the required permissions have been explicitly granted through a policy. For details about what permissions are required to run the DeleteDirectory operation, see Directory Service API Permissions: Actions, Resources, and Conditions Reference.
    @Sendable
    @inlinable
    public func deleteDirectory(_ input: DeleteDirectoryRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DeleteDirectoryResult {
        try await self.client.execute(
            operation: "DeleteDirectory", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Deletes an Directory Service directory. Before you call DeleteDirectory, ensure that all of the required permissions have been explicitly granted through a policy. For details about what permissions are required to run the DeleteDirectory operation, see Directory Service API Permissions: Actions, Resources, and Conditions Reference.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory to delete.
    ///   - logger: Logger use during operation
    @inlinable
    public func deleteDirectory(
        directoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DeleteDirectoryResult {
        let input = DeleteDirectoryRequest(
            directoryId: directoryId
        )
        return try await self.deleteDirectory(input, logger: logger)
    }

    /// Deletes the specified log subscription.
    @Sendable
    @inlinable
    public func deleteLogSubscription(_ input: DeleteLogSubscriptionRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DeleteLogSubscriptionResult {
        try await self.client.execute(
            operation: "DeleteLogSubscription", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Deletes the specified log subscription.
    ///
    /// Parameters:
    ///   - directoryId: Identifier of the directory whose log subscription you want to delete.
    ///   - logger: Logger use during operation
    @inlinable
    public func deleteLogSubscription(
        directoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DeleteLogSubscriptionResult {
        let input = DeleteLogSubscriptionRequest(
            directoryId: directoryId
        )
        return try await self.deleteLogSubscription(input, logger: logger)
    }

    /// Deletes a directory snapshot.
    @Sendable
    @inlinable
    public func deleteSnapshot(_ input: DeleteSnapshotRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DeleteSnapshotResult {
        try await self.client.execute(
            operation: "DeleteSnapshot", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Deletes a directory snapshot.
    ///
    /// Parameters:
    ///   - snapshotId: The identifier of the directory snapshot to be deleted.
    ///   - logger: Logger use during operation
    @inlinable
    public func deleteSnapshot(
        snapshotId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DeleteSnapshotResult {
        let input = DeleteSnapshotRequest(
            snapshotId: snapshotId
        )
        return try await self.deleteSnapshot(input, logger: logger)
    }

    /// Deletes an existing trust relationship between your Managed Microsoft AD directory and an external domain.
    @Sendable
    @inlinable
    public func deleteTrust(_ input: DeleteTrustRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DeleteTrustResult {
        try await self.client.execute(
            operation: "DeleteTrust", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Deletes an existing trust relationship between your Managed Microsoft AD directory and an external domain.
    ///
    /// Parameters:
    ///   - deleteAssociatedConditionalForwarder: Delete a conditional forwarder as part of a DeleteTrustRequest.
    ///   - trustId: The Trust ID of the trust relationship to be deleted.
    ///   - logger: Logger use during operation
    @inlinable
    public func deleteTrust(
        deleteAssociatedConditionalForwarder: Bool? = nil,
        trustId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DeleteTrustResult {
        let input = DeleteTrustRequest(
            deleteAssociatedConditionalForwarder: deleteAssociatedConditionalForwarder, 
            trustId: trustId
        )
        return try await self.deleteTrust(input, logger: logger)
    }

    /// Deletes from the system the certificate that was registered for secure LDAP or client certificate authentication.
    @Sendable
    @inlinable
    public func deregisterCertificate(_ input: DeregisterCertificateRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DeregisterCertificateResult {
        try await self.client.execute(
            operation: "DeregisterCertificate", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Deletes from the system the certificate that was registered for secure LDAP or client certificate authentication.
    ///
    /// Parameters:
    ///   - certificateId: The identifier of the certificate.
    ///   - directoryId: The identifier of the directory.
    ///   - logger: Logger use during operation
    @inlinable
    public func deregisterCertificate(
        certificateId: String,
        directoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DeregisterCertificateResult {
        let input = DeregisterCertificateRequest(
            certificateId: certificateId, 
            directoryId: directoryId
        )
        return try await self.deregisterCertificate(input, logger: logger)
    }

    /// Removes the specified directory as a publisher to the specified Amazon SNS topic.
    @Sendable
    @inlinable
    public func deregisterEventTopic(_ input: DeregisterEventTopicRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DeregisterEventTopicResult {
        try await self.client.execute(
            operation: "DeregisterEventTopic", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Removes the specified directory as a publisher to the specified Amazon SNS topic.
    ///
    /// Parameters:
    ///   - directoryId: The Directory ID to remove as a publisher. This directory will no longer send messages to the specified Amazon SNS topic.
    ///   - topicName: The name of the Amazon SNS topic from which to remove the directory as a publisher.
    ///   - logger: Logger use during operation
    @inlinable
    public func deregisterEventTopic(
        directoryId: String,
        topicName: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DeregisterEventTopicResult {
        let input = DeregisterEventTopicRequest(
            directoryId: directoryId, 
            topicName: topicName
        )
        return try await self.deregisterEventTopic(input, logger: logger)
    }

    /// Displays information about the certificate registered for secure LDAP or client certificate authentication.
    @Sendable
    @inlinable
    public func describeCertificate(_ input: DescribeCertificateRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeCertificateResult {
        try await self.client.execute(
            operation: "DescribeCertificate", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Displays information about the certificate registered for secure LDAP or client certificate authentication.
    ///
    /// Parameters:
    ///   - certificateId: The identifier of the certificate.
    ///   - directoryId: The identifier of the directory.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeCertificate(
        certificateId: String,
        directoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeCertificateResult {
        let input = DescribeCertificateRequest(
            certificateId: certificateId, 
            directoryId: directoryId
        )
        return try await self.describeCertificate(input, logger: logger)
    }

    /// Retrieves information about the type of client authentication for the specified directory, if the type is specified. If no type is specified, information about all client authentication types that are supported for the specified directory is retrieved. Currently, only SmartCard is supported.
    @Sendable
    @inlinable
    public func describeClientAuthenticationSettings(_ input: DescribeClientAuthenticationSettingsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeClientAuthenticationSettingsResult {
        try await self.client.execute(
            operation: "DescribeClientAuthenticationSettings", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Retrieves information about the type of client authentication for the specified directory, if the type is specified. If no type is specified, information about all client authentication types that are supported for the specified directory is retrieved. Currently, only SmartCard is supported.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory for which to retrieve information.
    ///   - limit: The maximum number of items to return. If this value is zero, the maximum number of items is specified by the limitations of the operation.
    ///   - nextToken: The DescribeClientAuthenticationSettingsResult.NextToken value from a previous call to DescribeClientAuthenticationSettings. Pass null if this is the first call.
    ///   - type: The type of client authentication for which to retrieve information. If no type is specified, a list of all client authentication types that are supported for the specified directory is retrieved.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeClientAuthenticationSettings(
        directoryId: String,
        limit: Int? = nil,
        nextToken: String? = nil,
        type: ClientAuthenticationType? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeClientAuthenticationSettingsResult {
        let input = DescribeClientAuthenticationSettingsRequest(
            directoryId: directoryId, 
            limit: limit, 
            nextToken: nextToken, 
            type: type
        )
        return try await self.describeClientAuthenticationSettings(input, logger: logger)
    }

    /// Obtains information about the conditional forwarders for this account. If no input parameters are provided for RemoteDomainNames, this request describes all conditional forwarders for the specified directory ID.
    @Sendable
    @inlinable
    public func describeConditionalForwarders(_ input: DescribeConditionalForwardersRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeConditionalForwardersResult {
        try await self.client.execute(
            operation: "DescribeConditionalForwarders", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Obtains information about the conditional forwarders for this account. If no input parameters are provided for RemoteDomainNames, this request describes all conditional forwarders for the specified directory ID.
    ///
    /// Parameters:
    ///   - directoryId: The directory ID for which to get the list of associated conditional forwarders.
    ///   - remoteDomainNames: The fully qualified domain names (FQDN) of the remote domains for which to get the list of associated conditional forwarders. If this member is null, all conditional forwarders are returned.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeConditionalForwarders(
        directoryId: String,
        remoteDomainNames: [String]? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeConditionalForwardersResult {
        let input = DescribeConditionalForwardersRequest(
            directoryId: directoryId, 
            remoteDomainNames: remoteDomainNames
        )
        return try await self.describeConditionalForwarders(input, logger: logger)
    }

    /// Obtains information about the directories that belong to this account. You can retrieve information about specific directories by passing the directory identifiers in the DirectoryIds parameter. Otherwise, all directories that belong to the current account are returned. This operation supports pagination with the use of the NextToken request and response parameters. If more results are available, the DescribeDirectoriesResult.NextToken member contains a token that you pass in the next call to DescribeDirectories to retrieve the next set of items. You can also specify a maximum number of return results with the Limit parameter.
    @Sendable
    @inlinable
    public func describeDirectories(_ input: DescribeDirectoriesRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeDirectoriesResult {
        try await self.client.execute(
            operation: "DescribeDirectories", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Obtains information about the directories that belong to this account. You can retrieve information about specific directories by passing the directory identifiers in the DirectoryIds parameter. Otherwise, all directories that belong to the current account are returned. This operation supports pagination with the use of the NextToken request and response parameters. If more results are available, the DescribeDirectoriesResult.NextToken member contains a token that you pass in the next call to DescribeDirectories to retrieve the next set of items. You can also specify a maximum number of return results with the Limit parameter.
    ///
    /// Parameters:
    ///   - directoryIds: A list of identifiers of the directories for which to obtain the information. If this member is null, all directories that belong to the current account are returned. An empty list results in an InvalidParameterException being thrown.
    ///   - limit: The maximum number of items to return. If this value is zero, the maximum number of items is specified by the limitations of the operation.
    ///   - nextToken: The DescribeDirectoriesResult.NextToken value from a previous call to DescribeDirectories. Pass null if this is the first call.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeDirectories(
        directoryIds: [String]? = nil,
        limit: Int? = nil,
        nextToken: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeDirectoriesResult {
        let input = DescribeDirectoriesRequest(
            directoryIds: directoryIds, 
            limit: limit, 
            nextToken: nextToken
        )
        return try await self.describeDirectories(input, logger: logger)
    }

    /// Obtains status of directory data access enablement through the Directory Service Data API for the specified directory.
    @Sendable
    @inlinable
    public func describeDirectoryDataAccess(_ input: DescribeDirectoryDataAccessRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeDirectoryDataAccessResult {
        try await self.client.execute(
            operation: "DescribeDirectoryDataAccess", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Obtains status of directory data access enablement through the Directory Service Data API for the specified directory.
    ///
    /// Parameters:
    ///   - directoryId: The directory identifier.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeDirectoryDataAccess(
        directoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeDirectoryDataAccessResult {
        let input = DescribeDirectoryDataAccessRequest(
            directoryId: directoryId
        )
        return try await self.describeDirectoryDataAccess(input, logger: logger)
    }

    /// Provides information about any domain controllers in your directory.
    @Sendable
    @inlinable
    public func describeDomainControllers(_ input: DescribeDomainControllersRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeDomainControllersResult {
        try await self.client.execute(
            operation: "DescribeDomainControllers", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Provides information about any domain controllers in your directory.
    ///
    /// Parameters:
    ///   - directoryId: Identifier of the directory for which to retrieve the domain controller information.
    ///   - domainControllerIds: A list of identifiers for the domain controllers whose information will be provided.
    ///   - limit: The maximum number of items to return.
    ///   - nextToken: The DescribeDomainControllers.NextToken value from a previous call to DescribeDomainControllers. Pass null if this is the first call.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeDomainControllers(
        directoryId: String,
        domainControllerIds: [String]? = nil,
        limit: Int? = nil,
        nextToken: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeDomainControllersResult {
        let input = DescribeDomainControllersRequest(
            directoryId: directoryId, 
            domainControllerIds: domainControllerIds, 
            limit: limit, 
            nextToken: nextToken
        )
        return try await self.describeDomainControllers(input, logger: logger)
    }

    /// Obtains information about which Amazon SNS topics receive status messages from the specified directory. If no input parameters are provided, such as DirectoryId or TopicName, this request describes all of the associations in the account.
    @Sendable
    @inlinable
    public func describeEventTopics(_ input: DescribeEventTopicsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeEventTopicsResult {
        try await self.client.execute(
            operation: "DescribeEventTopics", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Obtains information about which Amazon SNS topics receive status messages from the specified directory. If no input parameters are provided, such as DirectoryId or TopicName, this request describes all of the associations in the account.
    ///
    /// Parameters:
    ///   - directoryId: The Directory ID for which to get the list of associated Amazon SNS topics. If this member is null, associations for all Directory IDs are returned.
    ///   - topicNames: A list of Amazon SNS topic names for which to obtain the information. If this member is null, all associations for the specified Directory ID are returned. An empty list results in an InvalidParameterException being thrown.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeEventTopics(
        directoryId: String? = nil,
        topicNames: [String]? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeEventTopicsResult {
        let input = DescribeEventTopicsRequest(
            directoryId: directoryId, 
            topicNames: topicNames
        )
        return try await self.describeEventTopics(input, logger: logger)
    }

    /// Describes the status of LDAP security for the specified directory.
    @Sendable
    @inlinable
    public func describeLDAPSSettings(_ input: DescribeLDAPSSettingsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeLDAPSSettingsResult {
        try await self.client.execute(
            operation: "DescribeLDAPSSettings", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Describes the status of LDAP security for the specified directory.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory.
    ///   - limit: Specifies the number of items that should be displayed on one page.
    ///   - nextToken: The type of next token used for pagination.
    ///   - type: The type of LDAP security to enable. Currently only the value Client is supported.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeLDAPSSettings(
        directoryId: String,
        limit: Int? = nil,
        nextToken: String? = nil,
        type: LDAPSType? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeLDAPSSettingsResult {
        let input = DescribeLDAPSSettingsRequest(
            directoryId: directoryId, 
            limit: limit, 
            nextToken: nextToken, 
            type: type
        )
        return try await self.describeLDAPSSettings(input, logger: logger)
    }

    /// Provides information about the Regions that are configured for multi-Region replication.
    @Sendable
    @inlinable
    public func describeRegions(_ input: DescribeRegionsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeRegionsResult {
        try await self.client.execute(
            operation: "DescribeRegions", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Provides information about the Regions that are configured for multi-Region replication.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory.
    ///   - nextToken: The DescribeRegionsResult.NextToken value from a previous call to DescribeRegions. Pass null if this is the first call.
    ///   - regionName: The name of the Region. For example, us-east-1.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeRegions(
        directoryId: String,
        nextToken: String? = nil,
        regionName: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeRegionsResult {
        let input = DescribeRegionsRequest(
            directoryId: directoryId, 
            nextToken: nextToken, 
            regionName: regionName
        )
        return try await self.describeRegions(input, logger: logger)
    }

    /// Retrieves information about the configurable settings for the specified directory.
    @Sendable
    @inlinable
    public func describeSettings(_ input: DescribeSettingsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeSettingsResult {
        try await self.client.execute(
            operation: "DescribeSettings", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Retrieves information about the configurable settings for the specified directory.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory for which to retrieve information.
    ///   - nextToken: The DescribeSettingsResult.NextToken value from a previous call to DescribeSettings. Pass null if this is the first call.
    ///   - status: The status of the directory settings for which to retrieve information.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeSettings(
        directoryId: String,
        nextToken: String? = nil,
        status: DirectoryConfigurationStatus? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeSettingsResult {
        let input = DescribeSettingsRequest(
            directoryId: directoryId, 
            nextToken: nextToken, 
            status: status
        )
        return try await self.describeSettings(input, logger: logger)
    }

    /// Returns the shared directories in your account.
    @Sendable
    @inlinable
    public func describeSharedDirectories(_ input: DescribeSharedDirectoriesRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeSharedDirectoriesResult {
        try await self.client.execute(
            operation: "DescribeSharedDirectories", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Returns the shared directories in your account.
    ///
    /// Parameters:
    ///   - limit: The number of shared directories to return in the response object.
    ///   - nextToken: The DescribeSharedDirectoriesResult.NextToken value from a previous call to DescribeSharedDirectories. Pass null if this is the first call.
    ///   - ownerDirectoryId: Returns the identifier of the directory in the directory owner account.
    ///   - sharedDirectoryIds: A list of identifiers of all shared directories in your account.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeSharedDirectories(
        limit: Int? = nil,
        nextToken: String? = nil,
        ownerDirectoryId: String,
        sharedDirectoryIds: [String]? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeSharedDirectoriesResult {
        let input = DescribeSharedDirectoriesRequest(
            limit: limit, 
            nextToken: nextToken, 
            ownerDirectoryId: ownerDirectoryId, 
            sharedDirectoryIds: sharedDirectoryIds
        )
        return try await self.describeSharedDirectories(input, logger: logger)
    }

    /// Obtains information about the directory snapshots that belong to this account. This operation supports pagination with the use of the NextToken request and response parameters. If more results are available, the DescribeSnapshots.NextToken member contains a token that you pass in the next call to DescribeSnapshots to retrieve the next set of items. You can also specify a maximum number of return results with the Limit parameter.
    @Sendable
    @inlinable
    public func describeSnapshots(_ input: DescribeSnapshotsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeSnapshotsResult {
        try await self.client.execute(
            operation: "DescribeSnapshots", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Obtains information about the directory snapshots that belong to this account. This operation supports pagination with the use of the NextToken request and response parameters. If more results are available, the DescribeSnapshots.NextToken member contains a token that you pass in the next call to DescribeSnapshots to retrieve the next set of items. You can also specify a maximum number of return results with the Limit parameter.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory for which to retrieve snapshot information.
    ///   - limit: The maximum number of objects to return.
    ///   - nextToken: The DescribeSnapshotsResult.NextToken value from a previous call to DescribeSnapshots. Pass null if this is the first call.
    ///   - snapshotIds: A list of identifiers of the snapshots to obtain the information for. If this member is null or empty, all snapshots are returned using the Limit and NextToken members.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeSnapshots(
        directoryId: String? = nil,
        limit: Int? = nil,
        nextToken: String? = nil,
        snapshotIds: [String]? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeSnapshotsResult {
        let input = DescribeSnapshotsRequest(
            directoryId: directoryId, 
            limit: limit, 
            nextToken: nextToken, 
            snapshotIds: snapshotIds
        )
        return try await self.describeSnapshots(input, logger: logger)
    }

    /// Obtains information about the trust relationships for this account. If no input parameters are provided, such as DirectoryId or TrustIds, this request describes all the trust relationships belonging to the account.
    @Sendable
    @inlinable
    public func describeTrusts(_ input: DescribeTrustsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeTrustsResult {
        try await self.client.execute(
            operation: "DescribeTrusts", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Obtains information about the trust relationships for this account. If no input parameters are provided, such as DirectoryId or TrustIds, this request describes all the trust relationships belonging to the account.
    ///
    /// Parameters:
    ///   - directoryId: The Directory ID of the Amazon Web Services directory that is a part of the requested trust relationship.
    ///   - limit: The maximum number of objects to return.
    ///   - nextToken: The DescribeTrustsResult.NextToken value from a previous call to DescribeTrusts. Pass null if this is the first call.
    ///   - trustIds: A list of identifiers of the trust relationships for which to obtain the information. If this member is null, all trust relationships that belong to the current account are returned. An empty list results in an InvalidParameterException being thrown.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeTrusts(
        directoryId: String? = nil,
        limit: Int? = nil,
        nextToken: String? = nil,
        trustIds: [String]? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeTrustsResult {
        let input = DescribeTrustsRequest(
            directoryId: directoryId, 
            limit: limit, 
            nextToken: nextToken, 
            trustIds: trustIds
        )
        return try await self.describeTrusts(input, logger: logger)
    }

    ///  Describes the updates of a directory for a particular update type.
    @Sendable
    @inlinable
    public func describeUpdateDirectory(_ input: DescribeUpdateDirectoryRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DescribeUpdateDirectoryResult {
        try await self.client.execute(
            operation: "DescribeUpdateDirectory", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    ///  Describes the updates of a directory for a particular update type.
    ///
    /// Parameters:
    ///   - directoryId:  The unique identifier of the directory.
    ///   - nextToken:  The DescribeUpdateDirectoryResult. NextToken value from a previous call to DescribeUpdateDirectory. Pass null if this is the first call.
    ///   - regionName:  The name of the Region.
    ///   - updateType:  The type of updates you want to describe for the directory.
    ///   - logger: Logger use during operation
    @inlinable
    public func describeUpdateDirectory(
        directoryId: String,
        nextToken: String? = nil,
        regionName: String? = nil,
        updateType: UpdateType,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DescribeUpdateDirectoryResult {
        let input = DescribeUpdateDirectoryRequest(
            directoryId: directoryId, 
            nextToken: nextToken, 
            regionName: regionName, 
            updateType: updateType
        )
        return try await self.describeUpdateDirectory(input, logger: logger)
    }

    /// Disables alternative client authentication methods for the specified directory.
    @Sendable
    @inlinable
    public func disableClientAuthentication(_ input: DisableClientAuthenticationRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DisableClientAuthenticationResult {
        try await self.client.execute(
            operation: "DisableClientAuthentication", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Disables alternative client authentication methods for the specified directory.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory
    ///   - type: The type of client authentication to disable. Currently the only parameter "SmartCard" is supported.
    ///   - logger: Logger use during operation
    @inlinable
    public func disableClientAuthentication(
        directoryId: String,
        type: ClientAuthenticationType,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DisableClientAuthenticationResult {
        let input = DisableClientAuthenticationRequest(
            directoryId: directoryId, 
            type: type
        )
        return try await self.disableClientAuthentication(input, logger: logger)
    }

    /// Deactivates access to directory data via the Directory Service Data API for the specified directory. For more information, see Directory Service Data API Reference.
    @Sendable
    @inlinable
    public func disableDirectoryDataAccess(_ input: DisableDirectoryDataAccessRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DisableDirectoryDataAccessResult {
        try await self.client.execute(
            operation: "DisableDirectoryDataAccess", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Deactivates access to directory data via the Directory Service Data API for the specified directory. For more information, see Directory Service Data API Reference.
    ///
    /// Parameters:
    ///   - directoryId: The directory identifier.
    ///   - logger: Logger use during operation
    @inlinable
    public func disableDirectoryDataAccess(
        directoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DisableDirectoryDataAccessResult {
        let input = DisableDirectoryDataAccessRequest(
            directoryId: directoryId
        )
        return try await self.disableDirectoryDataAccess(input, logger: logger)
    }

    /// Deactivates LDAP secure calls for the specified directory.
    @Sendable
    @inlinable
    public func disableLDAPS(_ input: DisableLDAPSRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DisableLDAPSResult {
        try await self.client.execute(
            operation: "DisableLDAPS", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Deactivates LDAP secure calls for the specified directory.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory.
    ///   - type: The type of LDAP security to enable. Currently only the value Client is supported.
    ///   - logger: Logger use during operation
    @inlinable
    public func disableLDAPS(
        directoryId: String,
        type: LDAPSType,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DisableLDAPSResult {
        let input = DisableLDAPSRequest(
            directoryId: directoryId, 
            type: type
        )
        return try await self.disableLDAPS(input, logger: logger)
    }

    /// Disables multi-factor authentication (MFA) with the Remote Authentication Dial In User Service (RADIUS) server for an AD Connector or Microsoft AD directory.
    @Sendable
    @inlinable
    public func disableRadius(_ input: DisableRadiusRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DisableRadiusResult {
        try await self.client.execute(
            operation: "DisableRadius", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Disables multi-factor authentication (MFA) with the Remote Authentication Dial In User Service (RADIUS) server for an AD Connector or Microsoft AD directory.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory for which to disable MFA.
    ///   - logger: Logger use during operation
    @inlinable
    public func disableRadius(
        directoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DisableRadiusResult {
        let input = DisableRadiusRequest(
            directoryId: directoryId
        )
        return try await self.disableRadius(input, logger: logger)
    }

    /// Disables single-sign on for a directory.
    @Sendable
    @inlinable
    public func disableSso(_ input: DisableSsoRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> DisableSsoResult {
        try await self.client.execute(
            operation: "DisableSso", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Disables single-sign on for a directory.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory for which to disable single-sign on.
    ///   - password: The password of an alternate account to use to disable single-sign on. This is only used for AD Connector directories. For more information, see the UserName parameter.
    ///   - userName: The username of an alternate account to use to disable single-sign on. This is only used for AD Connector directories. This account must have privileges to remove a service principal name. If the AD Connector service account does not have privileges to remove a service principal name, you can specify an alternate account with the UserName and Password parameters. These credentials are only used to disable single sign-on and are not stored by the service. The AD Connector service account is not changed.
    ///   - logger: Logger use during operation
    @inlinable
    public func disableSso(
        directoryId: String,
        password: String? = nil,
        userName: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> DisableSsoResult {
        let input = DisableSsoRequest(
            directoryId: directoryId, 
            password: password, 
            userName: userName
        )
        return try await self.disableSso(input, logger: logger)
    }

    /// Enables alternative client authentication methods for the specified directory.
    @Sendable
    @inlinable
    public func enableClientAuthentication(_ input: EnableClientAuthenticationRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> EnableClientAuthenticationResult {
        try await self.client.execute(
            operation: "EnableClientAuthentication", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Enables alternative client authentication methods for the specified directory.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the specified directory.
    ///   - type: The type of client authentication to enable. Currently only the value SmartCard is supported. Smart card authentication in AD Connector requires that you enable Kerberos Constrained Delegation for the Service User to the LDAP service in your self-managed AD.
    ///   - logger: Logger use during operation
    @inlinable
    public func enableClientAuthentication(
        directoryId: String,
        type: ClientAuthenticationType,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> EnableClientAuthenticationResult {
        let input = EnableClientAuthenticationRequest(
            directoryId: directoryId, 
            type: type
        )
        return try await self.enableClientAuthentication(input, logger: logger)
    }

    /// Enables access to directory data via the Directory Service Data API for the specified directory. For more information, see Directory Service Data API Reference.
    @Sendable
    @inlinable
    public func enableDirectoryDataAccess(_ input: EnableDirectoryDataAccessRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> EnableDirectoryDataAccessResult {
        try await self.client.execute(
            operation: "EnableDirectoryDataAccess", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Enables access to directory data via the Directory Service Data API for the specified directory. For more information, see Directory Service Data API Reference.
    ///
    /// Parameters:
    ///   - directoryId: The directory identifier.
    ///   - logger: Logger use during operation
    @inlinable
    public func enableDirectoryDataAccess(
        directoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> EnableDirectoryDataAccessResult {
        let input = EnableDirectoryDataAccessRequest(
            directoryId: directoryId
        )
        return try await self.enableDirectoryDataAccess(input, logger: logger)
    }

    /// Activates the switch for the specific directory to always use LDAP secure calls.
    @Sendable
    @inlinable
    public func enableLDAPS(_ input: EnableLDAPSRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> EnableLDAPSResult {
        try await self.client.execute(
            operation: "EnableLDAPS", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Activates the switch for the specific directory to always use LDAP secure calls.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory.
    ///   - type: The type of LDAP security to enable. Currently only the value Client is supported.
    ///   - logger: Logger use during operation
    @inlinable
    public func enableLDAPS(
        directoryId: String,
        type: LDAPSType,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> EnableLDAPSResult {
        let input = EnableLDAPSRequest(
            directoryId: directoryId, 
            type: type
        )
        return try await self.enableLDAPS(input, logger: logger)
    }

    /// Enables multi-factor authentication (MFA) with the Remote Authentication Dial In User Service (RADIUS) server for an AD Connector or Microsoft AD directory.
    @Sendable
    @inlinable
    public func enableRadius(_ input: EnableRadiusRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> EnableRadiusResult {
        try await self.client.execute(
            operation: "EnableRadius", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Enables multi-factor authentication (MFA) with the Remote Authentication Dial In User Service (RADIUS) server for an AD Connector or Microsoft AD directory.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory for which to enable MFA.
    ///   - radiusSettings: A RadiusSettings object that contains information about the RADIUS server.
    ///   - logger: Logger use during operation
    @inlinable
    public func enableRadius(
        directoryId: String,
        radiusSettings: RadiusSettings,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> EnableRadiusResult {
        let input = EnableRadiusRequest(
            directoryId: directoryId, 
            radiusSettings: radiusSettings
        )
        return try await self.enableRadius(input, logger: logger)
    }

    /// Enables single sign-on for a directory. Single sign-on allows users in your directory to access certain Amazon Web Services services from a computer joined to the directory without having to enter their credentials separately.
    @Sendable
    @inlinable
    public func enableSso(_ input: EnableSsoRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> EnableSsoResult {
        try await self.client.execute(
            operation: "EnableSso", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Enables single sign-on for a directory. Single sign-on allows users in your directory to access certain Amazon Web Services services from a computer joined to the directory without having to enter their credentials separately.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory for which to enable single-sign on.
    ///   - password: The password of an alternate account to use to enable single-sign on. This is only used for AD Connector directories. For more information, see the UserName parameter.
    ///   - userName: The username of an alternate account to use to enable single-sign on. This is only used for AD Connector directories. This account must have privileges to add a service principal name. If the AD Connector service account does not have privileges to add a service principal name, you can specify an alternate account with the UserName and Password parameters. These credentials are only used to enable single sign-on and are not stored by the service. The AD Connector service account is not changed.
    ///   - logger: Logger use during operation
    @inlinable
    public func enableSso(
        directoryId: String,
        password: String? = nil,
        userName: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> EnableSsoResult {
        let input = EnableSsoRequest(
            directoryId: directoryId, 
            password: password, 
            userName: userName
        )
        return try await self.enableSso(input, logger: logger)
    }

    /// Obtains directory limit information for the current Region.
    @Sendable
    @inlinable
    public func getDirectoryLimits(_ input: GetDirectoryLimitsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> GetDirectoryLimitsResult {
        try await self.client.execute(
            operation: "GetDirectoryLimits", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Obtains directory limit information for the current Region.
    ///
    /// Parameters:
    ///   - logger: Logger use during operation
    @inlinable
    public func getDirectoryLimits(
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> GetDirectoryLimitsResult {
        let input = GetDirectoryLimitsRequest(
        )
        return try await self.getDirectoryLimits(input, logger: logger)
    }

    /// Obtains the manual snapshot limits for a directory.
    @Sendable
    @inlinable
    public func getSnapshotLimits(_ input: GetSnapshotLimitsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> GetSnapshotLimitsResult {
        try await self.client.execute(
            operation: "GetSnapshotLimits", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Obtains the manual snapshot limits for a directory.
    ///
    /// Parameters:
    ///   - directoryId: Contains the identifier of the directory to obtain the limits for.
    ///   - logger: Logger use during operation
    @inlinable
    public func getSnapshotLimits(
        directoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> GetSnapshotLimitsResult {
        let input = GetSnapshotLimitsRequest(
            directoryId: directoryId
        )
        return try await self.getSnapshotLimits(input, logger: logger)
    }

    /// For the specified directory, lists all the certificates registered for a secure LDAP or client certificate authentication.
    @Sendable
    @inlinable
    public func listCertificates(_ input: ListCertificatesRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListCertificatesResult {
        try await self.client.execute(
            operation: "ListCertificates", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// For the specified directory, lists all the certificates registered for a secure LDAP or client certificate authentication.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory.
    ///   - limit: The number of items that should show up on one page
    ///   - nextToken: A token for requesting another page of certificates if the NextToken response element indicates that more certificates are available. Use the value of the returned NextToken element in your request until the token comes back as null. Pass null if this is the first call.
    ///   - logger: Logger use during operation
    @inlinable
    public func listCertificates(
        directoryId: String,
        limit: Int? = nil,
        nextToken: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListCertificatesResult {
        let input = ListCertificatesRequest(
            directoryId: directoryId, 
            limit: limit, 
            nextToken: nextToken
        )
        return try await self.listCertificates(input, logger: logger)
    }

    /// Lists the address blocks that you have added to a directory.
    @Sendable
    @inlinable
    public func listIpRoutes(_ input: ListIpRoutesRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListIpRoutesResult {
        try await self.client.execute(
            operation: "ListIpRoutes", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Lists the address blocks that you have added to a directory.
    ///
    /// Parameters:
    ///   - directoryId: Identifier (ID) of the directory for which you want to retrieve the IP addresses.
    ///   - limit: Maximum number of items to return. If this value is zero, the maximum number of items is specified by the limitations of the operation.
    ///   - nextToken: The ListIpRoutes.NextToken value from a previous call to ListIpRoutes. Pass null if this is the first call.
    ///   - logger: Logger use during operation
    @inlinable
    public func listIpRoutes(
        directoryId: String,
        limit: Int? = nil,
        nextToken: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListIpRoutesResult {
        let input = ListIpRoutesRequest(
            directoryId: directoryId, 
            limit: limit, 
            nextToken: nextToken
        )
        return try await self.listIpRoutes(input, logger: logger)
    }

    /// Lists the active log subscriptions for the Amazon Web Services account.
    @Sendable
    @inlinable
    public func listLogSubscriptions(_ input: ListLogSubscriptionsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListLogSubscriptionsResult {
        try await self.client.execute(
            operation: "ListLogSubscriptions", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Lists the active log subscriptions for the Amazon Web Services account.
    ///
    /// Parameters:
    ///   - directoryId: If a DirectoryID is provided, lists only the log subscription associated with that directory. If no DirectoryId is provided, lists all log subscriptions associated with your Amazon Web Services account. If there are no log subscriptions for the Amazon Web Services account or the directory, an empty list will be returned.
    ///   - limit: The maximum number of items returned.
    ///   - nextToken: The token for the next set of items to return.
    ///   - logger: Logger use during operation
    @inlinable
    public func listLogSubscriptions(
        directoryId: String? = nil,
        limit: Int? = nil,
        nextToken: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListLogSubscriptionsResult {
        let input = ListLogSubscriptionsRequest(
            directoryId: directoryId, 
            limit: limit, 
            nextToken: nextToken
        )
        return try await self.listLogSubscriptions(input, logger: logger)
    }

    /// Lists all schema extensions applied to a Microsoft AD Directory.
    @Sendable
    @inlinable
    public func listSchemaExtensions(_ input: ListSchemaExtensionsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListSchemaExtensionsResult {
        try await self.client.execute(
            operation: "ListSchemaExtensions", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Lists all schema extensions applied to a Microsoft AD Directory.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory from which to retrieve the schema extension information.
    ///   - limit: The maximum number of items to return.
    ///   - nextToken: The ListSchemaExtensions.NextToken value from a previous call to ListSchemaExtensions. Pass null if this is the first call.
    ///   - logger: Logger use during operation
    @inlinable
    public func listSchemaExtensions(
        directoryId: String,
        limit: Int? = nil,
        nextToken: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListSchemaExtensionsResult {
        let input = ListSchemaExtensionsRequest(
            directoryId: directoryId, 
            limit: limit, 
            nextToken: nextToken
        )
        return try await self.listSchemaExtensions(input, logger: logger)
    }

    /// Lists all tags on a directory.
    @Sendable
    @inlinable
    public func listTagsForResource(_ input: ListTagsForResourceRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ListTagsForResourceResult {
        try await self.client.execute(
            operation: "ListTagsForResource", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Lists all tags on a directory.
    ///
    /// Parameters:
    ///   - limit: Reserved for future use.
    ///   - nextToken: Reserved for future use.
    ///   - resourceId: Identifier (ID) of the directory for which you want to retrieve tags.
    ///   - logger: Logger use during operation
    @inlinable
    public func listTagsForResource(
        limit: Int? = nil,
        nextToken: String? = nil,
        resourceId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ListTagsForResourceResult {
        let input = ListTagsForResourceRequest(
            limit: limit, 
            nextToken: nextToken, 
            resourceId: resourceId
        )
        return try await self.listTagsForResource(input, logger: logger)
    }

    /// Registers a certificate for a secure LDAP or client certificate authentication.
    @Sendable
    @inlinable
    public func registerCertificate(_ input: RegisterCertificateRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> RegisterCertificateResult {
        try await self.client.execute(
            operation: "RegisterCertificate", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Registers a certificate for a secure LDAP or client certificate authentication.
    ///
    /// Parameters:
    ///   - certificateData: The certificate PEM string that needs to be registered.
    ///   - clientCertAuthSettings: A ClientCertAuthSettings object that contains client certificate authentication settings.
    ///   - directoryId: The identifier of the directory.
    ///   - type: The function that the registered certificate performs. Valid values include ClientLDAPS or ClientCertAuth. The default value is ClientLDAPS.
    ///   - logger: Logger use during operation
    @inlinable
    public func registerCertificate(
        certificateData: String,
        clientCertAuthSettings: ClientCertAuthSettings? = nil,
        directoryId: String,
        type: CertificateType? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> RegisterCertificateResult {
        let input = RegisterCertificateRequest(
            certificateData: certificateData, 
            clientCertAuthSettings: clientCertAuthSettings, 
            directoryId: directoryId, 
            type: type
        )
        return try await self.registerCertificate(input, logger: logger)
    }

    /// Associates a directory with an Amazon SNS topic. This establishes the directory as a publisher to the specified Amazon SNS topic. You can then receive email or text (SMS) messages when the status of your directory changes. You get notified if your directory goes from an Active status to an Impaired or Inoperable status. You also receive a notification when the directory returns to an Active status.
    @Sendable
    @inlinable
    public func registerEventTopic(_ input: RegisterEventTopicRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> RegisterEventTopicResult {
        try await self.client.execute(
            operation: "RegisterEventTopic", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Associates a directory with an Amazon SNS topic. This establishes the directory as a publisher to the specified Amazon SNS topic. You can then receive email or text (SMS) messages when the status of your directory changes. You get notified if your directory goes from an Active status to an Impaired or Inoperable status. You also receive a notification when the directory returns to an Active status.
    ///
    /// Parameters:
    ///   - directoryId: The Directory ID that will publish status messages to the Amazon SNS topic.
    ///   - topicName: The Amazon SNS topic name to which the directory will publish status messages. This Amazon SNS topic must be in the same region as the specified Directory ID.
    ///   - logger: Logger use during operation
    @inlinable
    public func registerEventTopic(
        directoryId: String,
        topicName: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> RegisterEventTopicResult {
        let input = RegisterEventTopicRequest(
            directoryId: directoryId, 
            topicName: topicName
        )
        return try await self.registerEventTopic(input, logger: logger)
    }

    /// Rejects a directory sharing request that was sent from the directory owner account.
    @Sendable
    @inlinable
    public func rejectSharedDirectory(_ input: RejectSharedDirectoryRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> RejectSharedDirectoryResult {
        try await self.client.execute(
            operation: "RejectSharedDirectory", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Rejects a directory sharing request that was sent from the directory owner account.
    ///
    /// Parameters:
    ///   - sharedDirectoryId: Identifier of the shared directory in the directory consumer account. This identifier is different for each directory owner account.
    ///   - logger: Logger use during operation
    @inlinable
    public func rejectSharedDirectory(
        sharedDirectoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> RejectSharedDirectoryResult {
        let input = RejectSharedDirectoryRequest(
            sharedDirectoryId: sharedDirectoryId
        )
        return try await self.rejectSharedDirectory(input, logger: logger)
    }

    /// Removes IP address blocks from a directory.
    @Sendable
    @inlinable
    public func removeIpRoutes(_ input: RemoveIpRoutesRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> RemoveIpRoutesResult {
        try await self.client.execute(
            operation: "RemoveIpRoutes", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Removes IP address blocks from a directory.
    ///
    /// Parameters:
    ///   - cidrIps: IP address blocks that you want to remove.
    ///   - directoryId: Identifier (ID) of the directory from which you want to remove the IP addresses.
    ///   - logger: Logger use during operation
    @inlinable
    public func removeIpRoutes(
        cidrIps: [String],
        directoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> RemoveIpRoutesResult {
        let input = RemoveIpRoutesRequest(
            cidrIps: cidrIps, 
            directoryId: directoryId
        )
        return try await self.removeIpRoutes(input, logger: logger)
    }

    /// Stops all replication and removes the domain controllers from the specified Region. You cannot remove the primary Region with this operation. Instead, use the DeleteDirectory API.
    @Sendable
    @inlinable
    public func removeRegion(_ input: RemoveRegionRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> RemoveRegionResult {
        try await self.client.execute(
            operation: "RemoveRegion", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Stops all replication and removes the domain controllers from the specified Region. You cannot remove the primary Region with this operation. Instead, use the DeleteDirectory API.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory for which you want to remove Region replication.
    ///   - logger: Logger use during operation
    @inlinable
    public func removeRegion(
        directoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> RemoveRegionResult {
        let input = RemoveRegionRequest(
            directoryId: directoryId
        )
        return try await self.removeRegion(input, logger: logger)
    }

    /// Removes tags from a directory.
    @Sendable
    @inlinable
    public func removeTagsFromResource(_ input: RemoveTagsFromResourceRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> RemoveTagsFromResourceResult {
        try await self.client.execute(
            operation: "RemoveTagsFromResource", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Removes tags from a directory.
    ///
    /// Parameters:
    ///   - resourceId: Identifier (ID) of the directory from which to remove the tag.
    ///   - tagKeys: The tag key (name) of the tag to be removed.
    ///   - logger: Logger use during operation
    @inlinable
    public func removeTagsFromResource(
        resourceId: String,
        tagKeys: [String],
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> RemoveTagsFromResourceResult {
        let input = RemoveTagsFromResourceRequest(
            resourceId: resourceId, 
            tagKeys: tagKeys
        )
        return try await self.removeTagsFromResource(input, logger: logger)
    }

    /// Resets the password for any user in your Managed Microsoft AD or Simple AD directory. Disabled users will become enabled and can be authenticated following the API call. You can reset the password for any user in your directory with the following exceptions:   For Simple AD, you cannot reset the password for any user that is a member of either the Domain Admins or Enterprise Admins group except for the administrator user.   For Managed Microsoft AD, you can only reset the password for a user that is in an OU based off of the NetBIOS name that you typed when you created your directory. For example, you cannot reset the password for a user in the Amazon Web Services Reserved OU. For more information about the OU structure for an Managed Microsoft AD directory, see What Gets Created in the Directory Service Administration Guide.
    @Sendable
    @inlinable
    public func resetUserPassword(_ input: ResetUserPasswordRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ResetUserPasswordResult {
        try await self.client.execute(
            operation: "ResetUserPassword", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Resets the password for any user in your Managed Microsoft AD or Simple AD directory. Disabled users will become enabled and can be authenticated following the API call. You can reset the password for any user in your directory with the following exceptions:   For Simple AD, you cannot reset the password for any user that is a member of either the Domain Admins or Enterprise Admins group except for the administrator user.   For Managed Microsoft AD, you can only reset the password for a user that is in an OU based off of the NetBIOS name that you typed when you created your directory. For example, you cannot reset the password for a user in the Amazon Web Services Reserved OU. For more information about the OU structure for an Managed Microsoft AD directory, see What Gets Created in the Directory Service Administration Guide.
    ///
    /// Parameters:
    ///   - directoryId: Identifier of the Managed Microsoft AD or Simple AD directory in which the user resides.
    ///   - newPassword: The new password that will be reset.
    ///   - userName: The user name of the user whose password will be reset.
    ///   - logger: Logger use during operation
    @inlinable
    public func resetUserPassword(
        directoryId: String,
        newPassword: String,
        userName: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ResetUserPasswordResult {
        let input = ResetUserPasswordRequest(
            directoryId: directoryId, 
            newPassword: newPassword, 
            userName: userName
        )
        return try await self.resetUserPassword(input, logger: logger)
    }

    /// Restores a directory using an existing directory snapshot. When you restore a directory from a snapshot, any changes made to the directory after the snapshot date are overwritten. This action returns as soon as the restore operation is initiated. You can monitor the progress of the restore operation by calling the DescribeDirectories operation with the directory identifier. When the DirectoryDescription.Stage value changes to Active, the restore operation is complete.
    @Sendable
    @inlinable
    public func restoreFromSnapshot(_ input: RestoreFromSnapshotRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> RestoreFromSnapshotResult {
        try await self.client.execute(
            operation: "RestoreFromSnapshot", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Restores a directory using an existing directory snapshot. When you restore a directory from a snapshot, any changes made to the directory after the snapshot date are overwritten. This action returns as soon as the restore operation is initiated. You can monitor the progress of the restore operation by calling the DescribeDirectories operation with the directory identifier. When the DirectoryDescription.Stage value changes to Active, the restore operation is complete.
    ///
    /// Parameters:
    ///   - snapshotId: The identifier of the snapshot to restore from.
    ///   - logger: Logger use during operation
    @inlinable
    public func restoreFromSnapshot(
        snapshotId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> RestoreFromSnapshotResult {
        let input = RestoreFromSnapshotRequest(
            snapshotId: snapshotId
        )
        return try await self.restoreFromSnapshot(input, logger: logger)
    }

    /// Shares a specified directory (DirectoryId) in your Amazon Web Services account (directory owner) with another Amazon Web Services account (directory consumer). With this operation you can use your directory from any Amazon Web Services account and from any Amazon VPC within an Amazon Web Services Region. When you share your Managed Microsoft AD directory, Directory Service creates a shared directory in the directory consumer account. This shared directory contains the metadata to provide access to the directory within the directory owner account. The shared directory is visible in all VPCs in the directory consumer account. The ShareMethod parameter determines whether the specified directory can be shared between Amazon Web Services accounts inside the same Amazon Web Services organization (ORGANIZATIONS). It also determines whether you can share the directory with any other Amazon Web Services account either inside or outside of the organization (HANDSHAKE). The ShareNotes parameter is only used when HANDSHAKE is called, which sends a directory sharing request to the directory consumer.
    @Sendable
    @inlinable
    public func shareDirectory(_ input: ShareDirectoryRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> ShareDirectoryResult {
        try await self.client.execute(
            operation: "ShareDirectory", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Shares a specified directory (DirectoryId) in your Amazon Web Services account (directory owner) with another Amazon Web Services account (directory consumer). With this operation you can use your directory from any Amazon Web Services account and from any Amazon VPC within an Amazon Web Services Region. When you share your Managed Microsoft AD directory, Directory Service creates a shared directory in the directory consumer account. This shared directory contains the metadata to provide access to the directory within the directory owner account. The shared directory is visible in all VPCs in the directory consumer account. The ShareMethod parameter determines whether the specified directory can be shared between Amazon Web Services accounts inside the same Amazon Web Services organization (ORGANIZATIONS). It also determines whether you can share the directory with any other Amazon Web Services account either inside or outside of the organization (HANDSHAKE). The ShareNotes parameter is only used when HANDSHAKE is called, which sends a directory sharing request to the directory consumer.
    ///
    /// Parameters:
    ///   - directoryId: Identifier of the Managed Microsoft AD directory that you want to share with other Amazon Web Services accounts.
    ///   - shareMethod: The method used when sharing a directory to determine whether the directory should be shared within your Amazon Web Services organization (ORGANIZATIONS) or with any Amazon Web Services account by sending a directory sharing request (HANDSHAKE).
    ///   - shareNotes: A directory share request that is sent by the directory owner to the directory consumer. The request includes a typed message to help the directory consumer administrator determine whether to approve or reject the share invitation.
    ///   - shareTarget: Identifier for the directory consumer account with whom the directory is to be shared.
    ///   - logger: Logger use during operation
    @inlinable
    public func shareDirectory(
        directoryId: String,
        shareMethod: ShareMethod,
        shareNotes: String? = nil,
        shareTarget: ShareTarget,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> ShareDirectoryResult {
        let input = ShareDirectoryRequest(
            directoryId: directoryId, 
            shareMethod: shareMethod, 
            shareNotes: shareNotes, 
            shareTarget: shareTarget
        )
        return try await self.shareDirectory(input, logger: logger)
    }

    /// Applies a schema extension to a Microsoft AD directory.
    @Sendable
    @inlinable
    public func startSchemaExtension(_ input: StartSchemaExtensionRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> StartSchemaExtensionResult {
        try await self.client.execute(
            operation: "StartSchemaExtension", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Applies a schema extension to a Microsoft AD directory.
    ///
    /// Parameters:
    ///   - createSnapshotBeforeSchemaExtension: If true, creates a snapshot of the directory before applying the schema extension.
    ///   - description: A description of the schema extension.
    ///   - directoryId: The identifier of the directory for which the schema extension will be applied to.
    ///   - ldifContent: The LDIF file represented as a string. To construct the LdifContent string, precede each line as it would be formatted in an ldif file with \n. See the example request below for more details. The file size can be no larger than 1MB.
    ///   - logger: Logger use during operation
    @inlinable
    public func startSchemaExtension(
        createSnapshotBeforeSchemaExtension: Bool = false,
        description: String,
        directoryId: String,
        ldifContent: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> StartSchemaExtensionResult {
        let input = StartSchemaExtensionRequest(
            createSnapshotBeforeSchemaExtension: createSnapshotBeforeSchemaExtension, 
            description: description, 
            directoryId: directoryId, 
            ldifContent: ldifContent
        )
        return try await self.startSchemaExtension(input, logger: logger)
    }

    /// Stops the directory sharing between the directory owner and consumer accounts.
    @Sendable
    @inlinable
    public func unshareDirectory(_ input: UnshareDirectoryRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> UnshareDirectoryResult {
        try await self.client.execute(
            operation: "UnshareDirectory", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Stops the directory sharing between the directory owner and consumer accounts.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the Managed Microsoft AD directory that you want to stop sharing.
    ///   - unshareTarget: Identifier for the directory consumer account with whom the directory has to be unshared.
    ///   - logger: Logger use during operation
    @inlinable
    public func unshareDirectory(
        directoryId: String,
        unshareTarget: UnshareTarget,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> UnshareDirectoryResult {
        let input = UnshareDirectoryRequest(
            directoryId: directoryId, 
            unshareTarget: unshareTarget
        )
        return try await self.unshareDirectory(input, logger: logger)
    }

    /// Updates a conditional forwarder that has been set up for your Amazon Web Services directory.
    @Sendable
    @inlinable
    public func updateConditionalForwarder(_ input: UpdateConditionalForwarderRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> UpdateConditionalForwarderResult {
        try await self.client.execute(
            operation: "UpdateConditionalForwarder", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Updates a conditional forwarder that has been set up for your Amazon Web Services directory.
    ///
    /// Parameters:
    ///   - directoryId: The directory ID of the Amazon Web Services directory for which to update the conditional forwarder.
    ///   - dnsIpAddrs: The updated IP addresses of the remote DNS server associated with the conditional forwarder.
    ///   - remoteDomainName: The fully qualified domain name (FQDN) of the remote domain with which you will set up a trust relationship.
    ///   - logger: Logger use during operation
    @inlinable
    public func updateConditionalForwarder(
        directoryId: String,
        dnsIpAddrs: [String],
        remoteDomainName: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> UpdateConditionalForwarderResult {
        let input = UpdateConditionalForwarderRequest(
            directoryId: directoryId, 
            dnsIpAddrs: dnsIpAddrs, 
            remoteDomainName: remoteDomainName
        )
        return try await self.updateConditionalForwarder(input, logger: logger)
    }

    ///  Updates the directory for a particular update type.
    @Sendable
    @inlinable
    public func updateDirectorySetup(_ input: UpdateDirectorySetupRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> UpdateDirectorySetupResult {
        try await self.client.execute(
            operation: "UpdateDirectorySetup", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    ///  Updates the directory for a particular update type.
    ///
    /// Parameters:
    ///   - createSnapshotBeforeUpdate:  The boolean that specifies if a snapshot for the directory needs to be taken before updating the directory.
    ///   - directoryId:  The identifier of the directory on which you want to perform the update.
    ///   - osUpdateSettings:  The settings for the OS update that needs to be performed on the directory.
    ///   - updateType:  The type of update that needs to be performed on the directory. For example, OS.
    ///   - logger: Logger use during operation
    @inlinable
    public func updateDirectorySetup(
        createSnapshotBeforeUpdate: Bool? = nil,
        directoryId: String,
        osUpdateSettings: OSUpdateSettings? = nil,
        updateType: UpdateType,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> UpdateDirectorySetupResult {
        let input = UpdateDirectorySetupRequest(
            createSnapshotBeforeUpdate: createSnapshotBeforeUpdate, 
            directoryId: directoryId, 
            osUpdateSettings: osUpdateSettings, 
            updateType: updateType
        )
        return try await self.updateDirectorySetup(input, logger: logger)
    }

    /// Adds or removes domain controllers to or from the directory. Based on the difference between current value and new value (provided through this API call), domain controllers will be added or removed. It may take up to 45 minutes for any new domain controllers to become fully active once the requested number of domain controllers is updated. During this time, you cannot make another update request.
    @Sendable
    @inlinable
    public func updateNumberOfDomainControllers(_ input: UpdateNumberOfDomainControllersRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> UpdateNumberOfDomainControllersResult {
        try await self.client.execute(
            operation: "UpdateNumberOfDomainControllers", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Adds or removes domain controllers to or from the directory. Based on the difference between current value and new value (provided through this API call), domain controllers will be added or removed. It may take up to 45 minutes for any new domain controllers to become fully active once the requested number of domain controllers is updated. During this time, you cannot make another update request.
    ///
    /// Parameters:
    ///   - desiredNumber: The number of domain controllers desired in the directory.
    ///   - directoryId: Identifier of the directory to which the domain controllers will be added or removed.
    ///   - logger: Logger use during operation
    @inlinable
    public func updateNumberOfDomainControllers(
        desiredNumber: Int,
        directoryId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> UpdateNumberOfDomainControllersResult {
        let input = UpdateNumberOfDomainControllersRequest(
            desiredNumber: desiredNumber, 
            directoryId: directoryId
        )
        return try await self.updateNumberOfDomainControllers(input, logger: logger)
    }

    /// Updates the Remote Authentication Dial In User Service (RADIUS) server information for an AD Connector or Microsoft AD directory.
    @Sendable
    @inlinable
    public func updateRadius(_ input: UpdateRadiusRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> UpdateRadiusResult {
        try await self.client.execute(
            operation: "UpdateRadius", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Updates the Remote Authentication Dial In User Service (RADIUS) server information for an AD Connector or Microsoft AD directory.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory for which to update the RADIUS server information.
    ///   - radiusSettings: A RadiusSettings object that contains information about the RADIUS server.
    ///   - logger: Logger use during operation
    @inlinable
    public func updateRadius(
        directoryId: String,
        radiusSettings: RadiusSettings,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> UpdateRadiusResult {
        let input = UpdateRadiusRequest(
            directoryId: directoryId, 
            radiusSettings: radiusSettings
        )
        return try await self.updateRadius(input, logger: logger)
    }

    /// Updates the configurable settings for the specified directory.
    @Sendable
    @inlinable
    public func updateSettings(_ input: UpdateSettingsRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> UpdateSettingsResult {
        try await self.client.execute(
            operation: "UpdateSettings", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Updates the configurable settings for the specified directory.
    ///
    /// Parameters:
    ///   - directoryId: The identifier of the directory for which to update settings.
    ///   - settings: The list of Setting objects.
    ///   - logger: Logger use during operation
    @inlinable
    public func updateSettings(
        directoryId: String,
        settings: [Setting],
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> UpdateSettingsResult {
        let input = UpdateSettingsRequest(
            directoryId: directoryId, 
            settings: settings
        )
        return try await self.updateSettings(input, logger: logger)
    }

    /// Updates the trust that has been set up between your Managed Microsoft AD directory and an self-managed Active Directory.
    @Sendable
    @inlinable
    public func updateTrust(_ input: UpdateTrustRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> UpdateTrustResult {
        try await self.client.execute(
            operation: "UpdateTrust", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Updates the trust that has been set up between your Managed Microsoft AD directory and an self-managed Active Directory.
    ///
    /// Parameters:
    ///   - selectiveAuth: Updates selective authentication for the trust.
    ///   - trustId: Identifier of the trust relationship.
    ///   - logger: Logger use during operation
    @inlinable
    public func updateTrust(
        selectiveAuth: SelectiveAuth? = nil,
        trustId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> UpdateTrustResult {
        let input = UpdateTrustRequest(
            selectiveAuth: selectiveAuth, 
            trustId: trustId
        )
        return try await self.updateTrust(input, logger: logger)
    }

    /// Directory Service for Microsoft Active Directory allows you to configure and verify trust relationships. This action verifies a trust relationship between your Managed Microsoft AD directory and an external domain.
    @Sendable
    @inlinable
    public func verifyTrust(_ input: VerifyTrustRequest, logger: Logger = AWSClient.loggingDisabled) async throws -> VerifyTrustResult {
        try await self.client.execute(
            operation: "VerifyTrust", 
            path: "/", 
            httpMethod: .POST, 
            serviceConfig: self.config, 
            input: input, 
            logger: logger
        )
    }
    /// Directory Service for Microsoft Active Directory allows you to configure and verify trust relationships. This action verifies a trust relationship between your Managed Microsoft AD directory and an external domain.
    ///
    /// Parameters:
    ///   - trustId: The unique Trust ID of the trust relationship to verify.
    ///   - logger: Logger use during operation
    @inlinable
    public func verifyTrust(
        trustId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) async throws -> VerifyTrustResult {
        let input = VerifyTrustRequest(
            trustId: trustId
        )
        return try await self.verifyTrust(input, logger: logger)
    }
}

extension DirectoryService {
    /// Initializer required by `AWSService.with(middlewares:timeout:byteBufferAllocator:options)`. You are not able to use this initializer directly as there are not public
    /// initializers for `AWSServiceConfig.Patch`. Please use `AWSService.with(middlewares:timeout:byteBufferAllocator:options)` instead.
    public init(from: DirectoryService, patch: AWSServiceConfig.Patch) {
        self.client = from.client
        self.config = from.config.with(patch: patch)
    }
}

// MARK: Paginators

@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
extension DirectoryService {
    /// Return PaginatorSequence for operation ``describeClientAuthenticationSettings(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func describeClientAuthenticationSettingsPaginator(
        _ input: DescribeClientAuthenticationSettingsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<DescribeClientAuthenticationSettingsRequest, DescribeClientAuthenticationSettingsResult> {
        return .init(
            input: input,
            command: self.describeClientAuthenticationSettings,
            inputKey: \DescribeClientAuthenticationSettingsRequest.nextToken,
            outputKey: \DescribeClientAuthenticationSettingsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``describeClientAuthenticationSettings(_:logger:)``.
    ///
    /// - Parameters:
    ///   - directoryId: The identifier of the directory for which to retrieve information.
    ///   - limit: The maximum number of items to return. If this value is zero, the maximum number of items is specified by the limitations of the operation.
    ///   - type: The type of client authentication for which to retrieve information. If no type is specified, a list of all client authentication types that are supported for the specified directory is retrieved.
    ///   - logger: Logger used for logging
    @inlinable
    public func describeClientAuthenticationSettingsPaginator(
        directoryId: String,
        limit: Int? = nil,
        type: ClientAuthenticationType? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<DescribeClientAuthenticationSettingsRequest, DescribeClientAuthenticationSettingsResult> {
        let input = DescribeClientAuthenticationSettingsRequest(
            directoryId: directoryId, 
            limit: limit, 
            type: type
        )
        return self.describeClientAuthenticationSettingsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``describeDirectories(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func describeDirectoriesPaginator(
        _ input: DescribeDirectoriesRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<DescribeDirectoriesRequest, DescribeDirectoriesResult> {
        return .init(
            input: input,
            command: self.describeDirectories,
            inputKey: \DescribeDirectoriesRequest.nextToken,
            outputKey: \DescribeDirectoriesResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``describeDirectories(_:logger:)``.
    ///
    /// - Parameters:
    ///   - directoryIds: A list of identifiers of the directories for which to obtain the information. If this member is null, all directories that belong to the current account are returned. An empty list results in an InvalidParameterException being thrown.
    ///   - limit: The maximum number of items to return. If this value is zero, the maximum number of items is specified by the limitations of the operation.
    ///   - logger: Logger used for logging
    @inlinable
    public func describeDirectoriesPaginator(
        directoryIds: [String]? = nil,
        limit: Int? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<DescribeDirectoriesRequest, DescribeDirectoriesResult> {
        let input = DescribeDirectoriesRequest(
            directoryIds: directoryIds, 
            limit: limit
        )
        return self.describeDirectoriesPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``describeDomainControllers(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func describeDomainControllersPaginator(
        _ input: DescribeDomainControllersRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<DescribeDomainControllersRequest, DescribeDomainControllersResult> {
        return .init(
            input: input,
            command: self.describeDomainControllers,
            inputKey: \DescribeDomainControllersRequest.nextToken,
            outputKey: \DescribeDomainControllersResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``describeDomainControllers(_:logger:)``.
    ///
    /// - Parameters:
    ///   - directoryId: Identifier of the directory for which to retrieve the domain controller information.
    ///   - domainControllerIds: A list of identifiers for the domain controllers whose information will be provided.
    ///   - limit: The maximum number of items to return.
    ///   - logger: Logger used for logging
    @inlinable
    public func describeDomainControllersPaginator(
        directoryId: String,
        domainControllerIds: [String]? = nil,
        limit: Int? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<DescribeDomainControllersRequest, DescribeDomainControllersResult> {
        let input = DescribeDomainControllersRequest(
            directoryId: directoryId, 
            domainControllerIds: domainControllerIds, 
            limit: limit
        )
        return self.describeDomainControllersPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``describeLDAPSSettings(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func describeLDAPSSettingsPaginator(
        _ input: DescribeLDAPSSettingsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<DescribeLDAPSSettingsRequest, DescribeLDAPSSettingsResult> {
        return .init(
            input: input,
            command: self.describeLDAPSSettings,
            inputKey: \DescribeLDAPSSettingsRequest.nextToken,
            outputKey: \DescribeLDAPSSettingsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``describeLDAPSSettings(_:logger:)``.
    ///
    /// - Parameters:
    ///   - directoryId: The identifier of the directory.
    ///   - limit: Specifies the number of items that should be displayed on one page.
    ///   - type: The type of LDAP security to enable. Currently only the value Client is supported.
    ///   - logger: Logger used for logging
    @inlinable
    public func describeLDAPSSettingsPaginator(
        directoryId: String,
        limit: Int? = nil,
        type: LDAPSType? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<DescribeLDAPSSettingsRequest, DescribeLDAPSSettingsResult> {
        let input = DescribeLDAPSSettingsRequest(
            directoryId: directoryId, 
            limit: limit, 
            type: type
        )
        return self.describeLDAPSSettingsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``describeRegions(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func describeRegionsPaginator(
        _ input: DescribeRegionsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<DescribeRegionsRequest, DescribeRegionsResult> {
        return .init(
            input: input,
            command: self.describeRegions,
            inputKey: \DescribeRegionsRequest.nextToken,
            outputKey: \DescribeRegionsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``describeRegions(_:logger:)``.
    ///
    /// - Parameters:
    ///   - directoryId: The identifier of the directory.
    ///   - regionName: The name of the Region. For example, us-east-1.
    ///   - logger: Logger used for logging
    @inlinable
    public func describeRegionsPaginator(
        directoryId: String,
        regionName: String? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<DescribeRegionsRequest, DescribeRegionsResult> {
        let input = DescribeRegionsRequest(
            directoryId: directoryId, 
            regionName: regionName
        )
        return self.describeRegionsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``describeSharedDirectories(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func describeSharedDirectoriesPaginator(
        _ input: DescribeSharedDirectoriesRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<DescribeSharedDirectoriesRequest, DescribeSharedDirectoriesResult> {
        return .init(
            input: input,
            command: self.describeSharedDirectories,
            inputKey: \DescribeSharedDirectoriesRequest.nextToken,
            outputKey: \DescribeSharedDirectoriesResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``describeSharedDirectories(_:logger:)``.
    ///
    /// - Parameters:
    ///   - limit: The number of shared directories to return in the response object.
    ///   - ownerDirectoryId: Returns the identifier of the directory in the directory owner account.
    ///   - sharedDirectoryIds: A list of identifiers of all shared directories in your account.
    ///   - logger: Logger used for logging
    @inlinable
    public func describeSharedDirectoriesPaginator(
        limit: Int? = nil,
        ownerDirectoryId: String,
        sharedDirectoryIds: [String]? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<DescribeSharedDirectoriesRequest, DescribeSharedDirectoriesResult> {
        let input = DescribeSharedDirectoriesRequest(
            limit: limit, 
            ownerDirectoryId: ownerDirectoryId, 
            sharedDirectoryIds: sharedDirectoryIds
        )
        return self.describeSharedDirectoriesPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``describeSnapshots(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func describeSnapshotsPaginator(
        _ input: DescribeSnapshotsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<DescribeSnapshotsRequest, DescribeSnapshotsResult> {
        return .init(
            input: input,
            command: self.describeSnapshots,
            inputKey: \DescribeSnapshotsRequest.nextToken,
            outputKey: \DescribeSnapshotsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``describeSnapshots(_:logger:)``.
    ///
    /// - Parameters:
    ///   - directoryId: The identifier of the directory for which to retrieve snapshot information.
    ///   - limit: The maximum number of objects to return.
    ///   - snapshotIds: A list of identifiers of the snapshots to obtain the information for. If this member is null or empty, all snapshots are returned using the Limit and NextToken members.
    ///   - logger: Logger used for logging
    @inlinable
    public func describeSnapshotsPaginator(
        directoryId: String? = nil,
        limit: Int? = nil,
        snapshotIds: [String]? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<DescribeSnapshotsRequest, DescribeSnapshotsResult> {
        let input = DescribeSnapshotsRequest(
            directoryId: directoryId, 
            limit: limit, 
            snapshotIds: snapshotIds
        )
        return self.describeSnapshotsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``describeTrusts(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func describeTrustsPaginator(
        _ input: DescribeTrustsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<DescribeTrustsRequest, DescribeTrustsResult> {
        return .init(
            input: input,
            command: self.describeTrusts,
            inputKey: \DescribeTrustsRequest.nextToken,
            outputKey: \DescribeTrustsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``describeTrusts(_:logger:)``.
    ///
    /// - Parameters:
    ///   - directoryId: The Directory ID of the Amazon Web Services directory that is a part of the requested trust relationship.
    ///   - limit: The maximum number of objects to return.
    ///   - trustIds: A list of identifiers of the trust relationships for which to obtain the information. If this member is null, all trust relationships that belong to the current account are returned. An empty list results in an InvalidParameterException being thrown.
    ///   - logger: Logger used for logging
    @inlinable
    public func describeTrustsPaginator(
        directoryId: String? = nil,
        limit: Int? = nil,
        trustIds: [String]? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<DescribeTrustsRequest, DescribeTrustsResult> {
        let input = DescribeTrustsRequest(
            directoryId: directoryId, 
            limit: limit, 
            trustIds: trustIds
        )
        return self.describeTrustsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``describeUpdateDirectory(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func describeUpdateDirectoryPaginator(
        _ input: DescribeUpdateDirectoryRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<DescribeUpdateDirectoryRequest, DescribeUpdateDirectoryResult> {
        return .init(
            input: input,
            command: self.describeUpdateDirectory,
            inputKey: \DescribeUpdateDirectoryRequest.nextToken,
            outputKey: \DescribeUpdateDirectoryResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``describeUpdateDirectory(_:logger:)``.
    ///
    /// - Parameters:
    ///   - directoryId:  The unique identifier of the directory.
    ///   - regionName:  The name of the Region.
    ///   - updateType:  The type of updates you want to describe for the directory.
    ///   - logger: Logger used for logging
    @inlinable
    public func describeUpdateDirectoryPaginator(
        directoryId: String,
        regionName: String? = nil,
        updateType: UpdateType,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<DescribeUpdateDirectoryRequest, DescribeUpdateDirectoryResult> {
        let input = DescribeUpdateDirectoryRequest(
            directoryId: directoryId, 
            regionName: regionName, 
            updateType: updateType
        )
        return self.describeUpdateDirectoryPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listCertificates(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listCertificatesPaginator(
        _ input: ListCertificatesRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListCertificatesRequest, ListCertificatesResult> {
        return .init(
            input: input,
            command: self.listCertificates,
            inputKey: \ListCertificatesRequest.nextToken,
            outputKey: \ListCertificatesResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listCertificates(_:logger:)``.
    ///
    /// - Parameters:
    ///   - directoryId: The identifier of the directory.
    ///   - limit: The number of items that should show up on one page
    ///   - logger: Logger used for logging
    @inlinable
    public func listCertificatesPaginator(
        directoryId: String,
        limit: Int? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListCertificatesRequest, ListCertificatesResult> {
        let input = ListCertificatesRequest(
            directoryId: directoryId, 
            limit: limit
        )
        return self.listCertificatesPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listIpRoutes(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listIpRoutesPaginator(
        _ input: ListIpRoutesRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListIpRoutesRequest, ListIpRoutesResult> {
        return .init(
            input: input,
            command: self.listIpRoutes,
            inputKey: \ListIpRoutesRequest.nextToken,
            outputKey: \ListIpRoutesResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listIpRoutes(_:logger:)``.
    ///
    /// - Parameters:
    ///   - directoryId: Identifier (ID) of the directory for which you want to retrieve the IP addresses.
    ///   - limit: Maximum number of items to return. If this value is zero, the maximum number of items is specified by the limitations of the operation.
    ///   - logger: Logger used for logging
    @inlinable
    public func listIpRoutesPaginator(
        directoryId: String,
        limit: Int? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListIpRoutesRequest, ListIpRoutesResult> {
        let input = ListIpRoutesRequest(
            directoryId: directoryId, 
            limit: limit
        )
        return self.listIpRoutesPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listLogSubscriptions(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listLogSubscriptionsPaginator(
        _ input: ListLogSubscriptionsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListLogSubscriptionsRequest, ListLogSubscriptionsResult> {
        return .init(
            input: input,
            command: self.listLogSubscriptions,
            inputKey: \ListLogSubscriptionsRequest.nextToken,
            outputKey: \ListLogSubscriptionsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listLogSubscriptions(_:logger:)``.
    ///
    /// - Parameters:
    ///   - directoryId: If a DirectoryID is provided, lists only the log subscription associated with that directory. If no DirectoryId is provided, lists all log subscriptions associated with your Amazon Web Services account. If there are no log subscriptions for the Amazon Web Services account or the directory, an empty list will be returned.
    ///   - limit: The maximum number of items returned.
    ///   - logger: Logger used for logging
    @inlinable
    public func listLogSubscriptionsPaginator(
        directoryId: String? = nil,
        limit: Int? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListLogSubscriptionsRequest, ListLogSubscriptionsResult> {
        let input = ListLogSubscriptionsRequest(
            directoryId: directoryId, 
            limit: limit
        )
        return self.listLogSubscriptionsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listSchemaExtensions(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listSchemaExtensionsPaginator(
        _ input: ListSchemaExtensionsRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListSchemaExtensionsRequest, ListSchemaExtensionsResult> {
        return .init(
            input: input,
            command: self.listSchemaExtensions,
            inputKey: \ListSchemaExtensionsRequest.nextToken,
            outputKey: \ListSchemaExtensionsResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listSchemaExtensions(_:logger:)``.
    ///
    /// - Parameters:
    ///   - directoryId: The identifier of the directory from which to retrieve the schema extension information.
    ///   - limit: The maximum number of items to return.
    ///   - logger: Logger used for logging
    @inlinable
    public func listSchemaExtensionsPaginator(
        directoryId: String,
        limit: Int? = nil,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListSchemaExtensionsRequest, ListSchemaExtensionsResult> {
        let input = ListSchemaExtensionsRequest(
            directoryId: directoryId, 
            limit: limit
        )
        return self.listSchemaExtensionsPaginator(input, logger: logger)
    }

    /// Return PaginatorSequence for operation ``listTagsForResource(_:logger:)``.
    ///
    /// - Parameters:
    ///   - input: Input for operation
    ///   - logger: Logger used for logging
    @inlinable
    public func listTagsForResourcePaginator(
        _ input: ListTagsForResourceRequest,
        logger: Logger = AWSClient.loggingDisabled
    ) -> AWSClient.PaginatorSequence<ListTagsForResourceRequest, ListTagsForResourceResult> {
        return .init(
            input: input,
            command: self.listTagsForResource,
            inputKey: \ListTagsForResourceRequest.nextToken,
            outputKey: \ListTagsForResourceResult.nextToken,
            logger: logger
        )
    }
    /// Return PaginatorSequence for operation ``listTagsForResource(_:logger:)``.
    ///
    /// - Parameters:
    ///   - limit: Reserved for future use.
    ///   - resourceId: Identifier (ID) of the directory for which you want to retrieve tags.
    ///   - logger: Logger used for logging
    @inlinable
    public func listTagsForResourcePaginator(
        limit: Int? = nil,
        resourceId: String,
        logger: Logger = AWSClient.loggingDisabled        
    ) -> AWSClient.PaginatorSequence<ListTagsForResourceRequest, ListTagsForResourceResult> {
        let input = ListTagsForResourceRequest(
            limit: limit, 
            resourceId: resourceId
        )
        return self.listTagsForResourcePaginator(input, logger: logger)
    }
}

extension DirectoryService.DescribeClientAuthenticationSettingsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.DescribeClientAuthenticationSettingsRequest {
        return .init(
            directoryId: self.directoryId,
            limit: self.limit,
            nextToken: token,
            type: self.type
        )
    }
}

extension DirectoryService.DescribeDirectoriesRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.DescribeDirectoriesRequest {
        return .init(
            directoryIds: self.directoryIds,
            limit: self.limit,
            nextToken: token
        )
    }
}

extension DirectoryService.DescribeDomainControllersRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.DescribeDomainControllersRequest {
        return .init(
            directoryId: self.directoryId,
            domainControllerIds: self.domainControllerIds,
            limit: self.limit,
            nextToken: token
        )
    }
}

extension DirectoryService.DescribeLDAPSSettingsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.DescribeLDAPSSettingsRequest {
        return .init(
            directoryId: self.directoryId,
            limit: self.limit,
            nextToken: token,
            type: self.type
        )
    }
}

extension DirectoryService.DescribeRegionsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.DescribeRegionsRequest {
        return .init(
            directoryId: self.directoryId,
            nextToken: token,
            regionName: self.regionName
        )
    }
}

extension DirectoryService.DescribeSharedDirectoriesRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.DescribeSharedDirectoriesRequest {
        return .init(
            limit: self.limit,
            nextToken: token,
            ownerDirectoryId: self.ownerDirectoryId,
            sharedDirectoryIds: self.sharedDirectoryIds
        )
    }
}

extension DirectoryService.DescribeSnapshotsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.DescribeSnapshotsRequest {
        return .init(
            directoryId: self.directoryId,
            limit: self.limit,
            nextToken: token,
            snapshotIds: self.snapshotIds
        )
    }
}

extension DirectoryService.DescribeTrustsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.DescribeTrustsRequest {
        return .init(
            directoryId: self.directoryId,
            limit: self.limit,
            nextToken: token,
            trustIds: self.trustIds
        )
    }
}

extension DirectoryService.DescribeUpdateDirectoryRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.DescribeUpdateDirectoryRequest {
        return .init(
            directoryId: self.directoryId,
            nextToken: token,
            regionName: self.regionName,
            updateType: self.updateType
        )
    }
}

extension DirectoryService.ListCertificatesRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.ListCertificatesRequest {
        return .init(
            directoryId: self.directoryId,
            limit: self.limit,
            nextToken: token
        )
    }
}

extension DirectoryService.ListIpRoutesRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.ListIpRoutesRequest {
        return .init(
            directoryId: self.directoryId,
            limit: self.limit,
            nextToken: token
        )
    }
}

extension DirectoryService.ListLogSubscriptionsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.ListLogSubscriptionsRequest {
        return .init(
            directoryId: self.directoryId,
            limit: self.limit,
            nextToken: token
        )
    }
}

extension DirectoryService.ListSchemaExtensionsRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.ListSchemaExtensionsRequest {
        return .init(
            directoryId: self.directoryId,
            limit: self.limit,
            nextToken: token
        )
    }
}

extension DirectoryService.ListTagsForResourceRequest: AWSPaginateToken {
    @inlinable
    public func usingPaginationToken(_ token: String) -> DirectoryService.ListTagsForResourceRequest {
        return .init(
            limit: self.limit,
            nextToken: token,
            resourceId: self.resourceId
        )
    }
}
